diff --git a/test/bytecode_3.3/05_store_locals.pyc b/test/bytecode_3.3/05_store_locals.pyc new file mode 100644 index 00000000..27cd578f Binary files /dev/null and b/test/bytecode_3.3/05_store_locals.pyc differ diff --git a/test/simple_source/bug33/05_store_name.py b/test/simple_source/bug33/05_store_locals.py similarity index 100% rename from test/simple_source/bug33/05_store_name.py rename to test/simple_source/bug33/05_store_locals.py diff --git a/uncompyle6/semantics/pysource.py b/uncompyle6/semantics/pysource.py index f16e4b7a..381c7a79 100644 --- a/uncompyle6/semantics/pysource.py +++ b/uncompyle6/semantics/pysource.py @@ -1962,11 +1962,16 @@ class SourceWalker(GenericASTTraversal, object): code._tokens = None # save memory assert ast == 'stmts' + if 3.0 <= self.version <= 3.3: + try: + if ast[0][0][0] == 'store_locals': + if self.hide_internal: del ast[0] + except: + pass + try: if ast[0][0] == NAME_MODULE: if self.hide_internal: del ast[0] - elif ast[1][0] == NAME_MODULE: - if self.hide_internal: del ast[1] pass except: pass