Author: Christian Tismer <[email protected]>
Branch: win64 test
Changeset: r45451:a44cc5113548
Date: 2011-07-09 18:04 +0200
http://bitbucket.org/pypy/pypy/changeset/a44cc5113548/
Log: Merge with default
diff --git a/pypy/jit/metainterp/test/test_ajit.py
b/pypy/jit/metainterp/test/test_ajit.py
--- a/pypy/jit/metainterp/test/test_ajit.py
+++ b/pypy/jit/metainterp/test/test_ajit.py
@@ -984,11 +984,14 @@
pass
class B(A):
pass
+ @dont_look_inside
+ def extern(n):
+ if n:
+ return A()
+ else:
+ return B()
def fn(n):
- if n:
- obj = A()
- else:
- obj = B()
+ obj = extern(n)
return isinstance(obj, B)
res = self.interp_operations(fn, [0])
assert res
@@ -1026,15 +1029,16 @@
pass
class B(A):
pass
- a = A()
- b = B()
+ @dont_look_inside
+ def extern(n):
+ if n == -7:
+ return None
+ elif n:
+ return A()
+ else:
+ return B()
def fn(n):
- if n == -7:
- obj = None
- elif n:
- obj = a
- else:
- obj = b
+ obj = extern(n)
return isinstance(obj, B) + isinstance(obj, B) + isinstance(obj,
B) + isinstance(obj, B)
res = self.interp_operations(fn, [0])
assert res == 4
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit