summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorcooldome <cdome@bk.ru>2018-03-08 09:56:32 +0000
committerAndreas Rumpf <rumpf_a@web.de>2018-03-08 10:56:32 +0100
commit63c28b973e84e86ad0b9a69cf683cf93809af4f2 (patch)
treeb74d61c25daad6d6e322f2997ca9c1e51dc77b24 /tests
parent67fd7a7f865e7e725dfcd4c2ec2c5840f3457f60 (diff)
downloadNim-63c28b973e84e86ad0b9a69cf683cf93809af4f2.tar.gz
Allow only single infix as in except branches. Fixes #7115 (#7132)
Diffstat (limited to 'tests')
-rw-r--r--tests/exception/texcas.nim8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/exception/texcas.nim b/tests/exception/texcas.nim
index 298aee707..7108e334c 100644
--- a/tests/exception/texcas.nim
+++ b/tests/exception/texcas.nim
@@ -32,3 +32,11 @@ proc testTryAsExpr(i: int) =
 test[Exception]()
 test2()
 testTryAsExpr(5)
+
+# see bug #7115
+doAssert(not compiles(
+  try: 
+    echo 1
+  except [KeyError as ex1, ValueError as ex2]:
+    echo 2
+))