This commit is contained in:
cooldome 2018-07-18 14:54:44 +02:00 • committed by Andreas Rumpf
commit a651809411
2 changed files with 19 additions and 6 deletions

View file

@ -43,4 +43,19 @@ macro repr_and_parse(fn: typed): typed =
echo fn_impl.repr
result = parseStmt(fn_impl.repr)
repr_and_parse(f)
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)