summaryrefslogtreecommitdiffstats
path: root/Modules/_sre.c
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2007-08-31 04:32:55 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2007-08-31 04:32:55 (GMT)
commit1fe5f388529dcdf674d53f7d67abc16c9c6ca5e5 (patch)
treeb35d6a88c4ded09687f9916e4d4c0b03bafde580 /Modules/_sre.c
parent538d17aa233e99a0652d0c6d482845e8e909b6e0 (diff)
downloadcpython-1fe5f388529dcdf674d53f7d67abc16c9c6ca5e5.zip
cpython-1fe5f388529dcdf674d53f7d67abc16c9c6ca5e5.tar.gz
cpython-1fe5f388529dcdf674d53f7d67abc16c9c6ca5e5.tar.bz2
Remove checking redundantly for checks of PyInt and PyLong.
Diffstat (limited to 'Modules/_sre.c')
-rw-r--r--Modules/_sre.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_sre.c b/Modules/_sre.c
index 20f98ca..03067cb 100644
--- a/Modules/_sre.c
+++ b/Modules/_sre.c
@@ -2764,7 +2764,7 @@ match_getindex(MatchObject* self, PyObject* index)
if (self->pattern->groupindex) {
index = PyObject_GetItem(self->pattern->groupindex, index);
if (index) {
- if (PyInt_Check(index) || PyLong_Check(index))
+ if (PyLong_Check(index))
i = PyInt_AsSsize_t(index);
Py_DECREF(index);
} else