Georg Brandl added the comment:
Same here. There is only ever one return value on error unless documented
otherwise, since the type of error is already contained in the exception that
is set on return.
--
nosy: +georg.brandl
resolution: -> works for me
status: open -> closed
__
Terry J. Reedy added the comment:
I am not much familiar with the C api but I presume that all functions return
-1 on error and that this is documented somewhere in the beginning. I also
presume that functions that return values thru passed in pointers and that are
documented as returning an
New submission from Nikolaus Rath :
http://docs.python.org/c-api/string.html says about the return value of
AsStringAndSize:
"If length is NULL, the resulting buffer may not contain NUL characters; if it
does, the function returns -1 and a TypeError is raised."
"If string is not a string obje