[pypy-commit] pypy default: Fix the flow object space for 0bb2bc25fcfc

arigo noreply at buildbot.pypy.org
Sat Nov 26 11:26:50 CET 2011


Author: Armin Rigo <arigo at tunes.org>
Branch: 
Changeset: r49805:7458773f3be0
Date: 2011-11-26 11:26 +0100
http://bitbucket.org/pypy/pypy/changeset/7458773f3be0/

Log:	Fix the flow object space for 0bb2bc25fcfc and b78a605fb452. Oups.

diff --git a/pypy/objspace/flow/objspace.py b/pypy/objspace/flow/objspace.py
--- a/pypy/objspace/flow/objspace.py
+++ b/pypy/objspace/flow/objspace.py
@@ -96,6 +96,12 @@
         self.executioncontext.recorder = previous_recorder
         self.concrete_mode -= 1
 
+    def is_w(self, w_one, w_two):
+        return self.is_true(self.is_(w_one, w_two))
+
+    is_ = None     # real version added by add_operations()
+    id  = None     # real version added by add_operations()
+
     def newdict(self):
         if self.concrete_mode:
             return Constant({})
diff --git a/pypy/objspace/flow/operation.py b/pypy/objspace/flow/operation.py
--- a/pypy/objspace/flow/operation.py
+++ b/pypy/objspace/flow/operation.py
@@ -315,7 +315,7 @@
 del _add_exceptions, _add_except_ovf
 
 def make_op(fs, name, symbol, arity, specialnames):
-    if hasattr(fs, name):
+    if getattr(fs, name, None) is not None:
         return
 
     op = None


More information about the pypy-commit mailing list