diff options
Diffstat (limited to 'Objects/tupleobject.c')
-rw-r--r-- | Objects/tupleobject.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Objects/tupleobject.c b/Objects/tupleobject.c index 2161ab9..53afab5 100644 --- a/Objects/tupleobject.c +++ b/Objects/tupleobject.c @@ -577,13 +577,11 @@ static PySequenceMethods tuple_as_sequence = { (objobjproc)tuplecontains, /* sq_contains */ }; -#define HASINDEX(o) PyType_HasFeature((o)->ob_type, Py_TPFLAGS_HAVE_INDEX) - static PyObject* tuplesubscript(PyTupleObject* self, PyObject* item) { PyNumberMethods *nb = item->ob_type->tp_as_number; - if (nb != NULL && HASINDEX(item) && nb->nb_index != NULL) { + if (nb != NULL && nb->nb_index != NULL) { Py_ssize_t i = nb->nb_index(item); if (i == -1 && PyErr_Occurred()) return NULL; |