28 Jun
2002
28 Jun
'02
4:01 a.m.
From: "Tim Peters"
Thanks for the loan of the eyeballs!
As long as I'm eyeballin' (and you're thankin'), I notice in PyInt_AsLong: if (op == NULL || (nb = op->ob_type->tp_as_number) == NULL || nb->nb_int == NULL) { PyErr_SetString(PyExc_TypeError, "an integer is required"); return -1; } But really, an integer isn't required; Any type with a tp_as_number section and a conversion to int will do. Should the error say "a numeric type convertible to int is required"? -Dave