diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/vm/tconstprocassignments.nim | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/vm/tconstprocassignments.nim b/tests/vm/tconstprocassignments.nim new file mode 100644 index 000000000..0e2d2ed16 --- /dev/null +++ b/tests/vm/tconstprocassignments.nim @@ -0,0 +1,18 @@ +discard """ + output: ''' +100 +100 +''' +""" + +proc f():int {.compileTime.} = 100 + +const F = f +echo F() + +const G = proc ():int = + let x = f + let y = x + y() + +echo G() |