mirror of
https://github.com/python/cpython.git
synced 2025-09-24 17:33:29 +00:00
gh-102304: Fix Py_INCREF() stable ABI in debug mode (#104763)
When Python is built in debug mode (if the Py_REF_DEBUG macro is
defined), the Py_INCREF() and Py_DECREF() function are now always
implemented as opaque functions to avoid leaking implementation
details like the "_Py_RefTotal" variable or the
_Py_DecRefTotal_DO_NOT_USE_THIS() function.
* Remove _Py_IncRefTotal_DO_NOT_USE_THIS() and
_Py_DecRefTotal_DO_NOT_USE_THIS() from the stable ABI.
* Remove _Py_NegativeRefcount() from limited C API.
(cherry picked from commit 92022d8416
)
This commit is contained in:
parent
2d9ead219e
commit
2bbb557b0f
5 changed files with 17 additions and 27 deletions
2
PC/python3dll.c
generated
2
PC/python3dll.c
generated
|
@ -17,9 +17,7 @@ EXPORT_FUNC(_Py_BuildValue_SizeT)
|
|||
EXPORT_FUNC(_Py_CheckRecursiveCall)
|
||||
EXPORT_FUNC(_Py_Dealloc)
|
||||
EXPORT_FUNC(_Py_DecRef)
|
||||
EXPORT_FUNC(_Py_DecRefTotal_DO_NOT_USE_THIS)
|
||||
EXPORT_FUNC(_Py_IncRef)
|
||||
EXPORT_FUNC(_Py_IncRefTotal_DO_NOT_USE_THIS)
|
||||
EXPORT_FUNC(_Py_NegativeRefcount)
|
||||
EXPORT_FUNC(_Py_VaBuildValue_SizeT)
|
||||
EXPORT_FUNC(_PyArg_Parse_SizeT)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue