[issue40989] [C API] Remove _Py_NewReference() and _Py_ForgetReference() from the public C API
STINNER Victor
report at bugs.python.org
Mon Jun 15 18:50:58 EDT 2020
STINNER Victor <vstinner at python.org> added the comment:
Work on this issue started in Python 3.9 with the following change of bpo-39542:
commit f58bd7c1693fe041f7296a5778d0a11287895648
Author: Victor Stinner <vstinner at python.org>
Date: Wed Feb 5 13:12:19 2020 +0100
bpo-39542: Make PyObject_INIT() opaque in limited C API (GH-18363)
In the limited C API, PyObject_INIT() and PyObject_INIT_VAR() are now
defined as aliases to PyObject_Init() and PyObject_InitVar() to make
their implementation opaque. It avoids to leak implementation details
in the limited C API.
Exclude the following functions from the limited C API, move them
from object.h to cpython/object.h:
* _Py_NewReference()
* _Py_ForgetReference()
* _PyTraceMalloc_NewReference()
* _Py_GetRefTotal()
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue40989>
_______________________________________
More information about the Python-bugs-list
mailing list