mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2024-11-23 13:09:49 +00:00
PyPy 3.2 bug confusing RETURN_END_IF for except
Also fix a instruction formatting bug
This commit is contained in:
parent
ac121076e6
commit
5c9c0228ee
@ -735,6 +735,10 @@ class Scanner3(scan.Scanner):
|
||||
self.structs.append({'type': 'if-then',
|
||||
'start': start,
|
||||
'end': rtarget})
|
||||
jump_prev = prev_op[offset]
|
||||
if self.is_pypy and code[jump_prev] == self.opc.COMPARE_OP:
|
||||
if self.opc.cmp_op[code[jump_prev+1]] == 'exception match':
|
||||
return
|
||||
self.return_end_ifs.add(prev_op[rtarget])
|
||||
|
||||
elif op in self.jump_if_pop:
|
||||
|
@ -69,8 +69,9 @@ class Token:
|
||||
pattr = "to " + str(self.pattr)
|
||||
pass
|
||||
elif self.op in self.opc.hascompare:
|
||||
pattr = self.opc.cmp_op[self.attr]
|
||||
# And so on. See xdis/bytecode.py get_instructions_bytes
|
||||
if isinstance(self.attr, int):
|
||||
pattr = self.opc.cmp_op[self.attr]
|
||||
# And so on. See xdis/bytecode.py get_instructions_bytes
|
||||
pass
|
||||
else:
|
||||
pattr = ''
|
||||
|
Loading…
Reference in New Issue
Block a user