diff options
-rw-r--r-- | Objects/object.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Objects/object.c b/Objects/object.c index 1283294..523a881 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -1497,6 +1497,10 @@ int PyObject_IsTrue(PyObject *v) { int res; + if (v == Py_True) + return 1; + if (v == Py_False) + return 0; if (v == Py_None) return 0; else if (v->ob_type->tp_as_number != NULL && |