Author: Ronan Lamy <[email protected]>
Branch: var-in-Some
Changeset: r73775:f06b2d847309
Date: 2014-10-04 20:42 +0100
http://bitbucket.org/pypy/pypy/changeset/f06b2d847309/

Log:    fix test_harmonic()

diff --git a/rpython/annotator/test/test_annrpython.py 
b/rpython/annotator/test/test_annrpython.py
--- a/rpython/annotator/test/test_annrpython.py
+++ b/rpython/annotator/test/test_annrpython.py
@@ -857,8 +857,11 @@
         s = a.build_types(snippet.harmonic, [int])
         assert s.knowntype == float
         # check that the list produced by range() is not mutated or resized
-        for value in a.bindings.values():
-            s_value = value.ann
+        graph = graphof(a, snippet.harmonic)
+        all_vars = set().union(*[block.getvariables() for block in 
graph.iterblocks()])
+        print all_vars
+        for var in all_vars:
+            s_value = var.binding.ann
             if isinstance(s_value, annmodel.SomeList):
                 assert not s_value.listdef.listitem.resized
                 assert not s_value.listdef.listitem.mutated
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to