diff --git a/Objects/abstract.c b/Objects/abstract.c index 8d3030a118a..305910c3584 100644 --- a/Objects/abstract.c +++ b/Objects/abstract.c @@ -1510,7 +1510,7 @@ PySequence_Check(PyObject *s) { if (PyDict_Check(s)) return 0; - return s != NULL && s->ob_type->tp_as_sequence && + return s->ob_type->tp_as_sequence && s->ob_type->tp_as_sequence->sq_item != NULL; }