[pypy-svn] r29536 - in pypy/dist/pypy/translator/cli: . test

antocuni at codespeak.net antocuni at codespeak.net
Fri Jun 30 16:19:39 CEST 2006


Author: antocuni
Date: Fri Jun 30 16:19:34 2006
New Revision: 29536

Modified:
   pypy/dist/pypy/translator/cli/database.py
   pypy/dist/pypy/translator/cli/test/test_rpython.py
Log:
The workaround in LowLevelDatabase is not for a gencli bug, but for an
ootype.Record bug (see revision r29534): the problem is related to
hashing, so using a set doesn't fix it, we need a list for ensuring
that __eq__ is called.

Don't skip a test that no longer fails.



Modified: pypy/dist/pypy/translator/cli/database.py
==============================================================================
--- pypy/dist/pypy/translator/cli/database.py	(original)
+++ pypy/dist/pypy/translator/cli/database.py	Fri Jun 30 16:19:34 2006
@@ -30,7 +30,7 @@
         self.delegates = {} # StaticMethod --> type_name
         self.const_names = set()
         self.name_count = 0
-        self._recorded_records = set() # XXX: temporary hack
+        self._recorded_records = [] # XXX: temporary hack
 
     def next_count(self):
         self.name_count += 1
@@ -45,7 +45,7 @@
     def pending_record(self, record):
         r = Record(self, record)
         if r not in self._recorded_records: # XXX: temporary hack
-            self._recorded_records.add(r)
+            self._recorded_records.append(r)
             self.pending_node(r)
         return r.get_name()
 

Modified: pypy/dist/pypy/translator/cli/test/test_rpython.py
==============================================================================
--- pypy/dist/pypy/translator/cli/test/test_rpython.py	(original)
+++ pypy/dist/pypy/translator/cli/test/test_rpython.py	Fri Jun 30 16:19:34 2006
@@ -65,9 +65,6 @@
     test_constant_tuple_contains2 = test_constant_tuple_contains
     test_constant_unichar_tuple_contains = test_constant_tuple_contains
 
-    def test_inst_tuple_add_getitem(self):
-        py.test.skip("Need to fix pending nodes rendering")
-
 
 class TestCliString(CliTest, BaseTestRstr):
     def test_char_isxxx(self):



More information about the Pypy-commit mailing list