diff options
Diffstat (limited to 'Objects/object.c')
-rw-r--r-- | Objects/object.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/object.c b/Objects/object.c index e202e9b..4d9f414 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -1246,8 +1246,8 @@ PyObject_IsTrue(PyObject *v) if (v == Py_None) return 0; else if (v->ob_type->tp_as_number != NULL && - v->ob_type->tp_as_number->nb_nonzero != NULL) - res = (*v->ob_type->tp_as_number->nb_nonzero)(v); + v->ob_type->tp_as_number->nb_bool != NULL) + res = (*v->ob_type->tp_as_number->nb_bool)(v); else if (v->ob_type->tp_as_mapping != NULL && v->ob_type->tp_as_mapping->mp_length != NULL) res = (*v->ob_type->tp_as_mapping->mp_length)(v); |