1. Pypy
  2. Untitled project
  3. pypy

Commits

Amaury Forgeot d'Arc  committed 81d8c93

Turn some rffi.LONG into lltype.Signed,
all tests in test_rffi.py pass

  • Participants
  • Parent commits 115ed6c
  • Branches real-rffi.INT

Comments (0)

Files changed (2)

File pypy/rlib/rdtoa.py

View file
  • Ignore whitespace
         try:
             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,))

File pypy/rpython/memory/gc/inspector.py

View file
  • Ignore whitespace
         self.gc = gc
         self.gcflag = gc.gcflag_extra
         self.fd = rffi.cast(rffi.INT, fd)
-        self.writebuffer = lltype.malloc(rffi.LONGP.TO, self.BUFSIZE,
-                                         flavor='raw')
+        self.writebuffer = lltype.malloc(rffi.CArrayPtr(lltype.Signed).TO,
+                                         self.BUFSIZE, flavor='raw')
         self.buf_count = 0
         if self.gcflag == 0:
             self.seen = AddressDict()