codegen doesn't produce line tracing commands anymore; fixes #1344

This commit is contained in:
Araq 2015-03-21 15:18:32 +01:00
commit 5641be51c1
9 changed files with 277 additions and 216 deletions

View file

@ -0,0 +1,43 @@
discard """
output: '''10
10
1
1
true'''
"""
# bug #1344
var expected: int
var x: range[1..10] = 10
try:
x += 1
echo x
except OverflowError, RangeError:
expected += 1
echo x
try:
inc x
echo x
except OverflowError, RangeError:
expected += 1
echo x
x = 1
try:
x -= 1
echo x
except OverflowError, RangeError:
expected += 1
echo x
try:
dec x
echo x
except OverflowError, RangeError:
expected += 1
echo x
echo expected == 4