summaryrefslogtreecommitdiffstats
path: root/Objects/enumobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/enumobject.c')
-rw-r--r--Objects/enumobject.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/enumobject.c b/Objects/enumobject.c
index 2b114a3..a76ba04 100644
--- a/Objects/enumobject.c
+++ b/Objects/enumobject.c
@@ -31,6 +31,7 @@ enum_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
Py_DECREF(en);
return NULL;
}
+ assert(PyLong_Check(start));
en->en_index = PyLong_AsSsize_t(start);
if (en->en_index == -1 && PyErr_Occurred()) {
PyErr_Clear();