-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
gh-120225: fix crash in compiler on empty block at end of exception handler #120235
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
explicit_jump->b_cold = 1; | ||
explicit_jump->b_next = b->b_next; | ||
explicit_jump->b_predecessors = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was missing here - it is needed later for line number propagation to work.
case True: | ||
pass | ||
case name_5 if f'e': | ||
{name_3: name_4 async for name_2 in name_5} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the exception handling block is coming from inlining this comprehension?
Thanks @iritkatriel for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13. |
…tion handler (pythonGH-120235) (cherry picked from commit 4fc82b6) Co-authored-by: Irit Katriel <[email protected]>
GH-120249 is a backport of this pull request to the 3.13 branch. |
|
Fixes #120225.
It's not necessary to set a line number here. It can be propagated later (and if it's not that's also ok, JUMP_NO_INTERRUPT doesn't require a line number).