diff options
Diffstat (limited to 'Objects/clinic/listobject.c.h')
-rw-r--r-- | Objects/clinic/listobject.c.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Objects/clinic/listobject.c.h b/Objects/clinic/listobject.c.h index 01e31d7..75ed9f9 100644 --- a/Objects/clinic/listobject.c.h +++ b/Objects/clinic/listobject.c.h @@ -299,7 +299,8 @@ list___init__(PyObject *self, PyObject *args, PyObject *kwargs) int return_value = -1; PyObject *iterable = NULL; - if (Py_IS_TYPE(self, &PyList_Type) && + if ((Py_IS_TYPE(self, &PyList_Type) || + Py_TYPE(self)->tp_new == PyList_Type.tp_new) && !_PyArg_NoKeywords("list", kwargs)) { goto exit; } @@ -352,4 +353,4 @@ list___reversed__(PyListObject *self, PyObject *Py_UNUSED(ignored)) { return list___reversed___impl(self); } -/*[clinic end generated code: output=0063aad535edf62d input=a9049054013a1b77]*/ +/*[clinic end generated code: output=acb2f87736311930 input=a9049054013a1b77]*/ |