Fix if return boundary in 3.6+

Fixes #209
This commit is contained in:
rocky
2019-03-10 05:59:15 -04:00
parent bfceeac6c8
commit dcad6cf6ce
10 changed files with 43 additions and 21 deletions

View File

@@ -920,6 +920,10 @@ class Scanner3(Scanner):
return
pass
pass
if self.version >= 3.4:
self.fixed_jumps[offset] = rtarget
if code[pre_rtarget] == self.opc.RETURN_VALUE:
# If we are at some sort of POP_JUMP_IF and the instruction before was
# COMPARE_OP exception-match, then pre_rtarget is not an end_if