diff --git a/test/bytecode_3.5/02_while_and.pyc b/test/bytecode_3.5/02_while_and.pyc new file mode 100644 index 00000000..ca19b17a Binary files /dev/null and b/test/bytecode_3.5/02_while_and.pyc differ diff --git a/test/simple_source/bug35/02_while_and.py b/test/simple_source/bug35/02_while_and.py new file mode 100644 index 00000000..53aa7b82 --- /dev/null +++ b/test/simple_source/bug35/02_while_and.py @@ -0,0 +1,4 @@ +# Bug in 3.5 cmd.py +# Bug is "while and" not getting handled properly +i, n = 0, 5 +while i < n and __file__ in (1,2): i += 1 diff --git a/uncompyle6/scanners/scanner3.py b/uncompyle6/scanners/scanner3.py index 4d87ac09..b6a3acec 100644 --- a/uncompyle6/scanners/scanner3.py +++ b/uncompyle6/scanners/scanner3.py @@ -948,7 +948,7 @@ class Scanner3(Scanner): self.not_continue.add(pre_rtarget) else: # For now, we'll only tag forward jump. - if self.version >= 3.5: + if self.version >= 3.6: if target > offset: self.fixed_jumps[offset] = target pass