Skip to content

Commit 4025d49

Browse files
committed
Add application example
1 parent 11cf8ec commit 4025d49

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Python/flowgraph.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ is_jump(cfg_instr *i)
4848
return OPCODE_HAS_JUMP(i->i_opcode);
4949
}
5050

51+
5152
/* One arg*/
5253
#define INSTR_SET_OP1(I, OP, ARG) \
5354
do { \
@@ -1495,6 +1496,8 @@ optimize_basic_block(PyObject *const_cache, basicblock *bb, PyObject *consts)
14951496
if (opcode == nextop &&
14961497
oparg == bb->b_instr[i+1].i_oparg &&
14971498
bb->b_instr[i].i_loc.lineno == bb->b_instr[i+1].i_loc.lineno) {
1499+
assert(OPCODE_NO_EXCEPTION(opcode));
1500+
assert(OPCODE_NO_EXCEPTION(nextop));
14981501
bb->b_instr[i].i_opcode = POP_TOP;
14991502
bb->b_instr[i].i_oparg = 0;
15001503
}

0 commit comments

Comments
 (0)