[pypy-svn] r61038 - pypy/branch/oo-jit/pypy/rpython/lltypesystem/test
arigo at codespeak.net
arigo at codespeak.net
Fri Jan 16 17:10:46 CET 2009
Author: arigo
Date: Fri Jan 16 17:10:45 2009
New Revision: 61038
Modified:
pypy/branch/oo-jit/pypy/rpython/lltypesystem/test/test_ll2ctypes.py
Log:
A test that shows a problem with a changing hash.
Modified: pypy/branch/oo-jit/pypy/rpython/lltypesystem/test/test_ll2ctypes.py
==============================================================================
--- pypy/branch/oo-jit/pypy/rpython/lltypesystem/test/test_ll2ctypes.py (original)
+++ pypy/branch/oo-jit/pypy/rpython/lltypesystem/test/test_ll2ctypes.py Fri Jan 16 17:10:45 2009
@@ -932,3 +932,12 @@
ref = lltype.cast_opaque_ptr(llmemory.GCREF, node)
back = rffi.cast(llmemory.GCREF, rffi.cast(lltype.Signed, ref))
assert lltype.cast_opaque_ptr(lltype.Ptr(NODE), ref) == node
+
+ def test_runtimetypeinfo_change(self):
+ p = lltype.opaqueptr(lltype.RuntimeTypeInfo, 'foo')
+ hash1 = hash(p._obj)
+ print repr(p)
+ lltype2ctypes(p)
+ print repr(p)
+ hash2 = hash(p._obj)
+ assert hash1 == hash2
More information about the Pypy-commit
mailing list