[pypy-svn] r32083 - pypy/branch/more-gckinds/pypy/rpython/lltypesystem

mwh at codespeak.net mwh at codespeak.net
Fri Sep 8 14:17:41 CEST 2006


Author: mwh
Date: Fri Sep  8 14:17:41 2006
New Revision: 32083

Modified:
   pypy/branch/more-gckinds/pypy/rpython/lltypesystem/lltype.py
Log:
so InteriorPtr._example wasn't right


Modified: pypy/branch/more-gckinds/pypy/rpython/lltypesystem/lltype.py
==============================================================================
--- pypy/branch/more-gckinds/pypy/rpython/lltypesystem/lltype.py	(original)
+++ pypy/branch/more-gckinds/pypy/rpython/lltypesystem/lltype.py	Fri Sep  8 14:17:41 2006
@@ -629,12 +629,12 @@
                              self.PARENTTYPE._short_name(),
                              '.'.join(map(str, self.offsets)))
     def _example(self):
-        ob = self.PARENTTYPE._container_example()
+        ob = Ptr(self.PARENTTYPE)._example()
         for o in self.offsets:
             if isinstance(o, str):
-                ob = ob._getattr(o)
+                ob = getattr(ob, o)
             else:
-                ob = ob.getitem(0)
+                ob = ob[0]
         return ob
 
 # ____________________________________________________________



More information about the Pypy-commit mailing list