Make comparison more consistent

This commit is contained in:
Raymond Hettinger 2015-10-09 00:42:47 -04:00
parent 7836a27ceb
commit 5098b58381
1 changed files with 1 additions and 1 deletions

View File

@ -331,7 +331,7 @@ builtin_any(PyModuleDef *module, PyObject *iterable)
Py_DECREF(it);
return NULL;
}
if (cmp == 1) {
if (cmp > 0) {
Py_DECREF(it);
Py_RETURN_TRUE;
}