mirror of
https://github.com/python/cpython.git
synced 2025-07-23 11:15:24 +00:00
bpo-35053: Define _PyTraceMalloc_NewReference in object.h (GH-10107)
_PyTraceMalloc_NewReference() is now called by _Py_NewReference(), so move its definition to object.h. Moreover, define it even if Py_LIMITED_API is defined, since _Py_NewReference() is also exposed even if Py_LIMITED_API is defined.
This commit is contained in:
parent
6c83d9f4a7
commit
c89a932714
3 changed files with 7 additions and 4 deletions
|
@ -765,6 +765,10 @@ PyAPI_FUNC(void) dec_count(PyTypeObject *);
|
|||
#define _Py_COUNT_ALLOCS_COMMA
|
||||
#endif /* COUNT_ALLOCS */
|
||||
|
||||
/* Update the Python traceback of an object. This function must be called
|
||||
when a memory block is reused from a free list. */
|
||||
PyAPI_FUNC(int) _PyTraceMalloc_NewReference(PyObject *op);
|
||||
|
||||
#ifdef Py_TRACE_REFS
|
||||
/* Py_TRACE_REFS is such major surgery that we call external routines. */
|
||||
PyAPI_FUNC(void) _Py_NewReference(PyObject *);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue