summary refs log tree commit diff stats
path: root/tests/macros/tmacrostmt.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/macros/tmacrostmt.nim')
-rw-r--r--tests/macros/tmacrostmt.nim17
1 files changed, 16 insertions, 1 deletions
diff --git a/tests/macros/tmacrostmt.nim b/tests/macros/tmacrostmt.nim
index a6e1e66dd..abb4cc050 100644
--- a/tests/macros/tmacrostmt.nim
+++ b/tests/macros/tmacrostmt.nim
@@ -43,4 +43,19 @@ macro repr_and_parse(fn: typed): typed =
   echo fn_impl.repr
   result = parseStmt(fn_impl.repr)
 
-repr_and_parse(f)
\ No newline at end of file
+repr_and_parse(f)
+
+
+#------------------------------------
+# bugs #8343 and #8344 
+proc one_if_proc(x, y : int): int =
+  if x < y: result = x
+  else: result = y
+
+proc test_block(x, y : int): int =
+  block label:
+    result = x
+    result = y
+
+repr_and_parse(one_if_proc)
+repr_and_parse(test_block)