Author: Armin Rigo <[email protected]>
Branch: stmgc-c7
Changeset: r70187:dc3260a800db
Date: 2014-03-23 09:21 +0100
http://bitbucket.org/pypy/pypy/changeset/dc3260a800db/

Log:    The old interface box.getaddr() should now only be used to cast a
        raw pointer to an address, not a GC pointer.

diff --git a/rpython/jit/metainterp/history.py 
b/rpython/jit/metainterp/history.py
--- a/rpython/jit/metainterp/history.py
+++ b/rpython/jit/metainterp/history.py
@@ -108,6 +108,7 @@
         raise NotImplementedError
 
     def getaddr(self):
+        "Only for raw addresses (BoxInt & ConstInt), not for GC addresses"
         raise NotImplementedError
 
     def sort_key(self):
@@ -321,9 +322,6 @@
         else:
             return 0
 
-    def getaddr(self):
-        return llmemory.cast_ptr_to_adr(self.value)
-
     def same_constant(self, other):
         if isinstance(other, ConstPtr):
             return self.value == other.value
@@ -494,9 +492,6 @@
         return lltype.cast_opaque_ptr(PTR, self.getref_base())
     getref._annspecialcase_ = 'specialize:arg(1)'
 
-    def getaddr(self):
-        return llmemory.cast_ptr_to_adr(self.value)
-
     def _get_hash_(self):
         if self.value:
             return lltype.identityhash(self.value)
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to