Author: Amaury Forgeot d'Arc <[email protected]>
Branch: py3k
Changeset: r47990:a522088e48aa
Date: 2011-10-12 22:19 +0200
http://bitbucket.org/pypy/pypy/changeset/a522088e48aa/
Log: Fix usage of a removed opcode
diff --git a/pypy/interpreter/astcompiler/assemble.py
b/pypy/interpreter/astcompiler/assemble.py
--- a/pypy/interpreter/astcompiler/assemble.py
+++ b/pypy/interpreter/astcompiler/assemble.py
@@ -490,6 +490,7 @@
ops.ROT_TWO : 0,
ops.ROT_THREE : 0,
ops.DUP_TOP : 1,
+ ops.DUP_TOP_TWO : 2,
ops.UNARY_POSITIVE : 0,
ops.UNARY_NEGATIVE : 0,
diff --git a/pypy/interpreter/astcompiler/codegen.py
b/pypy/interpreter/astcompiler/codegen.py
--- a/pypy/interpreter/astcompiler/codegen.py
+++ b/pypy/interpreter/astcompiler/codegen.py
@@ -1108,7 +1108,7 @@
else:
raise AssertionError("unknown slice type")
if ctx == ast.AugLoad:
- self.emit_op_arg(ops.DUP_TOPX, 2)
+ self.emit_op(ops.DUP_TOP_TWO)
elif ctx == ast.AugStore:
self.emit_op(ops.ROT_THREE)
self.emit_op(subscr_operations(ctx))
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit