[pypy-commit] pypy flowoperators: kill annoying special case for repr and str in make_op()

rlamy noreply at buildbot.pypy.org
Fri Jul 5 19:42:21 CEST 2013


Author: Ronan Lamy <ronan.lamy at gmail.com>
Branch: flowoperators
Changeset: r65221:8507c35cab3e
Date: 2013-05-07 13:50 +0100
http://bitbucket.org/pypy/pypy/changeset/8507c35cab3e/

Log:	kill annoying special case for repr and str in make_op()

diff --git a/rpython/flowspace/objspace.py b/rpython/flowspace/objspace.py
--- a/rpython/flowspace/objspace.py
+++ b/rpython/flowspace/objspace.py
@@ -416,13 +416,6 @@
         return make_impure_op(oper)
     elif name in ('id', 'hash', 'iter', 'userdel'):
         return make_impure_op(oper)
-    elif name in ('repr', 'str'):
-        rep = getattr(__builtin__, name)
-        def func(obj):
-            s = rep(obj)
-            if "at 0x" in s:
-                print >>sys.stderr, "Warning: captured address may be awkward"
-            return s
     else:
         func = oper.pyfunc
         arithmetic = hasattr(operation.op, name + '_ovf')


More information about the pypy-commit mailing list