[pypy-commit] pypy win64_gborg: got one of four things in test_typed.py to run.

ctismer noreply at buildbot.pypy.org
Mon Nov 7 00:41:09 CET 2011

Author: Christian Tismer <tismer at stackless.com>
Branch: win64_gborg
Changeset: r48856:dc81624b6a84
Date: 2011-11-07 00:40 +0100

Log:	got one of four things in test_typed.py to run. It is rffi related,
	the others probably as well. I want to add more structure to PyPy.
	Things like rffi should not be compatible with the target system at
	all. I would like to introduce explicit conversions, for every type.
	That would need some effort, but make an 'up-lifting' to a more OS
	independent build system much easier.

	Will elaborate on this, tomorrow.

diff --git a/pypy/rlib/rdtoa.py b/pypy/rlib/rdtoa.py
--- a/pypy/rlib/rdtoa.py
+++ b/pypy/rlib/rdtoa.py
@@ -58,8 +58,8 @@
             result = dg_strtod(ll_input, end_ptr)
-            endpos = (rffi.cast(rffi.LONG, end_ptr[0]) -
-                      rffi.cast(rffi.LONG, ll_input))
+            endpos = (rffi.cast(lltype.Signed, end_ptr[0]) -
+                      rffi.cast(lltype.Signed, ll_input))
             if endpos == 0 or endpos < len(input):
                 raise ValueError("invalid input at position %d" % (endpos,))

More information about the pypy-commit mailing list