diff options
author | Tomohiro <gpuppur@gmail.com> | 2018-10-12 16:00:27 +0900 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-10-12 09:00:27 +0200 |
commit | d2b04a8bc7a78845d25e8b789184ae54e98073ec (patch) | |
tree | 59bef75d781bd282e3cb5f6593861c03ee576d80 /doc | |
parent | 71636059e98ec83bbdb61d9b2627b948670475e8 (diff) | |
download | Nim-d2b04a8bc7a78845d25e8b789184ae54e98073ec.tar.gz |
manual: Remove stmt or expr template related text from manual (#9321)
Diffstat (limited to 'doc')
-rw-r--r-- | doc/manual.rst | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/doc/manual.rst b/doc/manual.rst index d64da0e3f..ee7609960 100644 --- a/doc/manual.rst +++ b/doc/manual.rst @@ -3037,7 +3037,7 @@ The `case expression` is again very similar to the case statement: As seen in the above example, the case expression can also introduce side effects. When multiple statements are given for a branch, Nim will use -the last expression as the result value, much like in an `expr` template. +the last expression as the result value. Table constructor ----------------- @@ -4611,8 +4611,8 @@ The concept types can be parametric just like the regular generic types: M.data[m * M.N + n] = v # Adapt the Matrix type to the concept's requirements - template Rows*(M: type Matrix): expr = M.M - template Cols*(M: type Matrix): expr = M.N + template Rows*(M: type Matrix): int = M.M + template Cols*(M: type Matrix): int = M.N template ValueType*(M: type Matrix): type = M.T ------------- @@ -5036,9 +5036,8 @@ an ``immediate`` pragma and then these templates do not take part in overloading resolution and the parameters' types are *ignored* by the compiler. Explicit immediate templates are now deprecated. -**Note**: For historical reasons ``stmt`` is an alias for ``typed`` and -``expr`` an alias for ``untyped``, but new code should use the newer, -clearer names. +**Note**: For historical reasons ``stmt`` was an alias for ``typed`` and +``expr`` was an alias for ``untyped``, but they are removed. Passing a code block to a template @@ -5129,9 +5128,6 @@ also ``varargs[untyped]`` so that not even the number of parameters is fixed: However, since a template cannot iterate over varargs, this feature is generally much more useful for macros. -**Note**: For historical reasons ``varargs[expr]`` is not equivalent -to ``varargs[untyped]``. - Symbol binding in templates --------------------------- |