Commit c18a6f46 authored by Guido van Rossum's avatar Guido van Rossum

Replace PyErr_BadArgument() error in PyInt_AsLong() with "an integer

is required" (we can't say more because we don't know in which context
it is called).
parent b8872e61
......@@ -198,7 +198,7 @@ PyInt_AsLong(op)
if (op == NULL || (nb = op->ob_type->tp_as_number) == NULL ||
nb->nb_int == NULL) {
PyErr_BadArgument();
PyErr_SetString(PyExc_TypeError, "an integer is required");
return -1;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment