PyInt_AsLong()

Fredrik Lundh fredrik at pythonware.com
Wed Apr 3 12:04:05 EST 2002


Ralf Juengling wrote:
> Okay. So the reason to indicate an error by '-1' is efficiency,
> I guess

the function has to return something. it might as well
return a known value...

> (i.e. calling PyErr_Occured() each time is more
> expensive than the prior check 'v == -1') ?

on most computers, yes.

</F>





More information about the Python-list mailing list