summaryrefslogtreecommitdiffstats
path: root/Modules/_sre.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2007-12-02 14:31:20 (GMT)
committerChristian Heimes <christian@cheimes.de>2007-12-02 14:31:20 (GMT)
commit217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2 (patch)
tree4737b4a91359c94953623ab9ee297e9a90f319e4 /Modules/_sre.c
parent1a3284ed69d545e4ef59869998cb8c29233a45fa (diff)
downloadcpython-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/_sre.c')
-rw-r--r--Modules/_sre.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/Modules/_sre.c b/Modules/_sre.c
index f4cd1fe..33f3759 100644
--- a/Modules/_sre.c
+++ b/Modules/_sre.c
@@ -2756,8 +2756,8 @@ match_getindex(MatchObject* self, PyObject* index)
/* Default value */
return 0;
- if (PyInt_Check(index))
- return PyInt_AsSsize_t(index);
+ if (PyLong_Check(index))
+ return PyLong_AsSsize_t(index);
i = -1;
@@ -2765,7 +2765,7 @@ match_getindex(MatchObject* self, PyObject* index)
index = PyObject_GetItem(self->pattern->groupindex, index);
if (index) {
if (PyLong_Check(index))
- i = PyInt_AsSsize_t(index);
+ i = PyLong_AsSsize_t(index);
Py_DECREF(index);
} else
PyErr_Clear();
@@ -2957,12 +2957,12 @@ _pair(Py_ssize_t i1, Py_ssize_t i2)
if (!pair)
return NULL;
- item = PyInt_FromSsize_t(i1);
+ item = PyLong_FromSsize_t(i1);
if (!item)
goto error;
PyTuple_SET_ITEM(pair, 0, item);
- item = PyInt_FromSsize_t(i2);
+ item = PyLong_FromSsize_t(i2);
if (!item)
goto error;
PyTuple_SET_ITEM(pair, 1, item);
@@ -3397,13 +3397,13 @@ PyMODINIT_FUNC init_sre(void)
return;
d = PyModule_GetDict(m);
- x = PyInt_FromLong(SRE_MAGIC);
+ x = PyLong_FromLong(SRE_MAGIC);
if (x) {
PyDict_SetItemString(d, "MAGIC", x);
Py_DECREF(x);
}
- x = PyInt_FromLong(sizeof(SRE_CODE));
+ x = PyLong_FromLong(sizeof(SRE_CODE));
if (x) {
PyDict_SetItemString(d, "CODESIZE", x);
Py_DECREF(x);