A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2011-October/114024.html below:

[Python-Dev] Identifier API

[Python-Dev] Identifier API [Python-Dev] Identifier APIHrvoje Niksic hrvoje.niksic at avl.com
Tue Oct 11 16:24:01 CEST 2011
On 10/11/2011 02:45 PM, Amaury Forgeot d'Arc wrote:
> It should also check for errors; in this case the initialization is a
> bit more verbose:
> if (PY_IDENTIFIER_INIT(update) < 0)
> <return NULL or return -1 or goto error>;

Error checking is somewhat more controversial because behavior in case 
of error differs between situations and coding patterns.  I think it 
should be up to the calling code to check for s_update remaining NULL. 
In my example, I would expect PyObject_CallMethodObj and similar to 
raise InternalError when passed a NULL pointer.  Since their return 
values are already checked, this should be enought to cover the unlikely 
case of identifier creation failing.

Hrvoje
More information about the Python-Dev mailing list

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