diff Objects/codeobject.c @ 67347:3bf4d9f1660a

Issue #9566: use Py_ssize_t instead of int
author Victor Stinner <victor.stinner@haypocalc.com>
date Tue, 04 Jan 2011 12:59:15 +0000
parents e8969fb822fc
children a0d4eda8da0a
line wrap: on
line diff
--- a/Objects/codeobject.c	Tue Jan 04 11:16:49 2011 +0000
+++ b/Objects/codeobject.c	Tue Jan 04 12:59:15 2011 +0000
@@ -492,7 +492,7 @@
 int
 PyCode_Addr2Line(PyCodeObject *co, int addrq)
 {
-    int size = PyBytes_Size(co->co_lnotab) / 2;
+    Py_ssize_t size = PyBytes_Size(co->co_lnotab) / 2;
     unsigned char *p = (unsigned char*)PyBytes_AsString(co->co_lnotab);
     int line = co->co_firstlineno;
     int addr = 0;
@@ -510,7 +510,8 @@
 int
 _PyCode_CheckLineNumber(PyCodeObject* co, int lasti, PyAddrPair *bounds)
 {
-    int size, addr, line;
+    Py_ssize_t size;
+    int addr, line;
     unsigned char* p;
 
     p = (unsigned char*)PyBytes_AS_STRING(co->co_lnotab);