diff options
author | Christian Heimes <christian@cheimes.de> | 2007-12-02 14:31:20 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2007-12-02 14:31:20 (GMT) |
commit | 217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2 (patch) | |
tree | 4737b4a91359c94953623ab9ee297e9a90f319e4 /Modules/_fileio.c | |
parent | 1a3284ed69d545e4ef59869998cb8c29233a45fa (diff) | |
download | cpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.zip cpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.tar.gz cpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.tar.bz2 |
Cleanup: Replaced most PyInt_ aliases with PyLong_ and disabled the aliases in intobject.h
Diffstat (limited to 'Modules/_fileio.c')
-rw-r--r-- | Modules/_fileio.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Modules/_fileio.c b/Modules/_fileio.c index 68b28d4..f3b20c9 100644 --- a/Modules/_fileio.c +++ b/Modules/_fileio.c @@ -326,7 +326,7 @@ fileio_fileno(PyFileIOObject *self) { if (self->fd < 0) return err_closed(); - return PyInt_FromLong((long) self->fd); + return PyLong_FromLong((long) self->fd); } static PyObject * @@ -388,7 +388,7 @@ fileio_readinto(PyFileIOObject *self, PyObject *args) return NULL; } - return PyInt_FromSsize_t(n); + return PyLong_FromSsize_t(n); } #define DEFAULT_BUFFER_SIZE (8*1024) @@ -521,7 +521,7 @@ fileio_write(PyFileIOObject *self, PyObject *args) return NULL; } - return PyInt_FromSsize_t(n); + return PyLong_FromSsize_t(n); } /* XXX Windows support below is likely incomplete */ @@ -561,10 +561,10 @@ portable_lseek(int fd, PyObject *posobj, int whence) return NULL; } #if !defined(HAVE_LARGEFILE_SUPPORT) - pos = PyInt_AsLong(posobj); + pos = PyLong_AsLong(posobj); #else pos = PyLong_Check(posobj) ? - PyLong_AsLongLong(posobj) : PyInt_AsLong(posobj); + PyLong_AsLongLong(posobj) : PyLong_AsLong(posobj); #endif if (PyErr_Occurred()) return NULL; @@ -581,7 +581,7 @@ portable_lseek(int fd, PyObject *posobj, int whence) return PyErr_SetFromErrno(PyExc_IOError); #if !defined(HAVE_LARGEFILE_SUPPORT) - return PyInt_FromLong(res); + return PyLong_FromLong(res); #else return PyLong_FromLongLong(res); #endif @@ -639,10 +639,10 @@ fileio_truncate(PyFileIOObject *self, PyObject *args) } #if !defined(HAVE_LARGEFILE_SUPPORT) - pos = PyInt_AsLong(posobj); + pos = PyLong_AsLong(posobj); #else pos = PyLong_Check(posobj) ? - PyLong_AsLongLong(posobj) : PyInt_AsLong(posobj); + PyLong_AsLongLong(posobj) : PyLong_AsLong(posobj); #endif if (PyErr_Occurred()) { Py_DECREF(posobj); |