diff options
Diffstat (limited to 'lib/system.nim')
-rwxr-xr-x | lib/system.nim | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/system.nim b/lib/system.nim index 79c014a7c..ae9d6b432 100755 --- a/lib/system.nim +++ b/lib/system.nim @@ -1257,7 +1257,9 @@ proc echo*[Ty](x: openarray[Ty]) {.magic: "Echo".} ## equivalent to ``writeln(stdout, x); flush(stdout)``. BUT: This is ## available for the ECMAScript target too! -template newException(exceptn, message: expr): expr = +template newException*(exceptn, message: expr): expr = + ## creates an exception object of type "exceptn" and sets its ``msg`` field + ## to `message`. Returns the new exception object. block: # open a new scope var e: ref exceptn |