Skip to content
Snippets Groups Projects
Commit e08395a3 authored by Damien George's avatar Damien George
Browse files

tests/misc: Add test for line number printing with large bytecode chunk.

parent cc2dbdd1
Branches
No related tags found
No related merge requests found
......@@ -41,3 +41,13 @@ try:
except Exception as e:
print('caught')
print_exc(e)
# Here we have a function with lots of bytecode generated for a single source-line, and
# there is an error right at the end of the bytecode. It should report the correct line.
def f():
f([1, 2], [1, 2], [1, 2], {1:1, 1:1, 1:1, 1:1, 1:1, 1:1, 1:X})
return 1
try:
f()
except Exception as e:
print_exc(e)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment