Correct location for syntax error in try-except (GH-25939) · python/cpython@8d4b184 · GitHub
Skip to content

Commit 8d4b184

Browse files
authored
Correct location for syntax error in try-except (GH-25939)
1 parent 60ba0b6 commit 8d4b184

3 files changed

Lines changed: 4 additions & 2 deletions

File tree

Lib/test/test_exceptions.py

Lines changed: 1 addition & 1 deletion
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Syntax errors when default ``except`` is not the last ``except`` are
2+
reported with the correct location. Patch by Mark Shannon.

Python/compile.c

Lines changed: 1 addition & 1 deletion

0 commit comments

Comments
 (0)