From: Benjamin Peterson Date: Sun, 1 Apr 2012 22:48:40 +0000 (-0400) Subject: remove extraneous condition X-Git-Tag: v3.3.0a3~334^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3471bb67e7add5c809c00e5c0977047017548b40;p=python remove extraneous condition --- diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 9f0ab15945..c12cd7ca32 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -464,12 +464,10 @@ type_set_bases(PyTypeObject *type, PyObject *value, void *context) type->tp_name, Py_TYPE(ob)->tp_name); return -1; } - if (PyType_Check(ob)) { - if (PyType_IsSubtype((PyTypeObject*)ob, type)) { - PyErr_SetString(PyExc_TypeError, - "a __bases__ item causes an inheritance cycle"); - return -1; - } + if (PyType_IsSubtype((PyTypeObject*)ob, type)) { + PyErr_SetString(PyExc_TypeError, + "a __bases__ item causes an inheritance cycle"); + return -1; } }