[Scott Gilbert] > ... > How would you designate failure/exceptions? size_t is unsigned everywhere > I can find it, Right, and the std requires that size_t resolve to an unsigned type, so that's reliable. > so it can't return a negative number on failure. The usual dodge is to return (and test against) (size_t)-1 in that case. If the caller sees that the result is (size_t)-1, then it also needs to call PyErr_Occurred() to see whether it's a normal, or error, return value (and if it is an error case, the routine had to have set a Python exception, so that PyErr_Occurred() returns true then). > I guess the void** could be filled in with NULL. Sounds easier to me <wink>.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4