' is optional in type suffixes for numerical literals

This commit is contained in:
Araq 2012-07-02 08:49:38 +02:00
commit 2e2650c708
6 changed files with 51 additions and 16 deletions

View file

@ -1662,6 +1662,10 @@ proc echo*[Ty](x: openarray[Ty]) {.magic: "Echo", noSideEffect.}
## available for the ECMAScript target too.
## Unlike other IO operations this is guaranteed to be thread-safe as
## ``echo`` is very often used for debugging convenience.
##
## As a special semantic rule, ``echo`` pretends to be free of
## side effects, so that it can be used for debugging routines marked as
## ``noSideEffect``.
template newException*(exceptn: typeDesc, message: string): expr =
## creates an exception object of type ``exceptn`` and sets its ``msg`` field