diff options
author | andri lim <jangko128@gmail.com> | 2017-07-17 13:07:47 +0700 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2017-07-17 08:07:47 +0200 |
commit | c245cfc1fd4143553bcce99669a85f093e4b88a7 (patch) | |
tree | f1eefd0151de85773cf282d60dfa3a0713a34cce /tests/js | |
parent | 3c36aed100e9e8c80b752d22848b6238311c6515 (diff) | |
download | Nim-c245cfc1fd4143553bcce99669a85f093e4b88a7.tar.gz |
fixes #5986 js backend failed to compile try ... except new syntax (#6116)
Diffstat (limited to 'tests/js')
-rw-r--r-- | tests/js/ttryexceptnewsyntax.nim | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/js/ttryexceptnewsyntax.nim b/tests/js/ttryexceptnewsyntax.nim new file mode 100644 index 000000000..2573c3727 --- /dev/null +++ b/tests/js/ttryexceptnewsyntax.nim @@ -0,0 +1,13 @@ +discard """ + output: '''hello''' +""" + +type + MyException = ref Exception + +#bug #5986 + +try: + raise MyException(msg: "hello") +except MyException as e: + echo e.msg |