Python 3.x control-flow bug...

"pass" statement inside "while True"
This commit is contained in:
rocky
2017-05-07 09:10:05 -04:00
parent 50d875f6a6
commit 605721c995
4 changed files with 15 additions and 5 deletions

View File

@@ -338,11 +338,7 @@ class Scanner3(Scanner):
(next_opname not in ('END_FINALLY', 'POP_BLOCK',
# Python 3.0 only uses POP_TOP
'POP_TOP'))):
if (self.version >= 3.4 or
(inst.offset not in self.not_continue) or
(tokens[-1].type == 'RETURN_VALUE')):
opname = 'CONTINUE'
pass
opname = 'CONTINUE'
else:
opname = 'JUMP_BACK'
# FIXME: this is a hack to catch stuff like: