mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
bpo-34880: Add the LOAD_ASSERTION_ERROR opcode. (GH-15073)
Fix assert statement misbehavior if AssertionError is shadowed.
This commit is contained in:
parent
8371799e30
commit
ce6a070414
14 changed files with 2664 additions and 2627 deletions
|
@ -147,7 +147,7 @@ def bug1333982(x=[]):
|
|||
dis_bug1333982 = """\
|
||||
%3d 0 LOAD_CONST 1 (0)
|
||||
2 POP_JUMP_IF_TRUE 26
|
||||
4 LOAD_GLOBAL 0 (AssertionError)
|
||||
4 LOAD_ASSERTION_ERROR
|
||||
6 LOAD_CONST 2 (<code object <listcomp> at 0x..., file "%s", line %d>)
|
||||
8 LOAD_CONST 3 ('bug1333982.<locals>.<listcomp>')
|
||||
10 MAKE_FUNCTION 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue