diff options
Diffstat (limited to 'web/news/e031_version_0_16_2.rst')
-rw-r--r-- | web/news/e031_version_0_16_2.rst | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/web/news/e031_version_0_16_2.rst b/web/news/e031_version_0_16_2.rst index 809910052..4c4cac129 100644 --- a/web/news/e031_version_0_16_2.rst +++ b/web/news/e031_version_0_16_2.rst @@ -96,6 +96,19 @@ remove the need for the ``newException`` template. - A new pragma ``.used`` can be used for symbols to prevent the "declared but not used" warning. More details can be found `here <http://nim-lang.org/docs/manual.html#pragmas-used-pragma>`_. +- The popular "colon block of statements" syntax is now also supported for + ``let`` and ``var`` statements: + +.. code-block:: nim + template ve(value, effect): untyped = + effect + val + + let x = ve(4): + echo "welcome to Nim!" + +This is particularly useful for DSLs that help in tree construction. + Bugfixes |