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/2004-July/046104.html below:

[Python-Dev] Proposal: C API Macro to decref and set to NULL

[Python-Dev] Proposal: C API Macro to decref and set to NULL [Python-Dev] Proposal: C API Macro to decref and set to NULLGuido van Rossum guido at python.org
Tue Jul 13 06:27:07 CEST 2004
> > Just my two cents, but the name suggests to me that it's doing
> > more than a simple decref and set to NULL.  I can't think of
> > anything else off the top of my head that seems obviously better
> > though.
> 
> Py_XDECREF_NULL?

Bleah.

In pystate.c you'll find:

#define ZAP(x) { \
	PyObject *tmp = (PyObject *)(x); \
	(x) = NULL; \
	Py_XDECREF(tmp); \
}

Call it Py_ZAP and you have my vote. :-)

--Guido van Rossum (home page: http://www.python.org/~guido/)
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