This commit is contained in:
Araq 2014-03-05 02:14:53 +01:00
commit aa92669d92
5 changed files with 47 additions and 6 deletions

13
tests/vm/twrongwhen.nim Normal file
View file

@ -0,0 +1,13 @@
discard """
output: "Error: cannot evaluate at compile time: x"
line: 7
"""
proc bla(x:int) =
when x == 0:
echo "oops"
else:
echo "good"
bla(2) # echos "oops"