diff --git a/Include/cpython/object.h b/Include/cpython/object.h index 5fcad55c5c9601..70f189c85698f2 100644 --- a/Include/cpython/object.h +++ b/Include/cpython/object.h @@ -327,16 +327,6 @@ _PyObject_GenericSetAttrWithDict(PyObject *, PyObject *, #define PyType_HasFeature(t,f) (((t)->tp_flags & (f)) != 0) -static inline void _Py_Dealloc_inline(PyObject *op) -{ - destructor dealloc = Py_TYPE(op)->tp_dealloc; -#ifdef Py_TRACE_REFS - _Py_ForgetReference(op); -#endif - (*dealloc)(op); -} -#define _Py_Dealloc(op) _Py_Dealloc_inline(op) - PyAPI_FUNC(PyObject *) _PyObject_FunctionStr(PyObject *); /* Safely decref `op` and set `op` to `op2`. diff --git a/Objects/object.c b/Objects/object.c index e6bfad4e7295e2..1884819b982c4a 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -2162,8 +2162,6 @@ _PyObject_AssertFailed(PyObject *obj, const char *expr, const char *msg, } -#undef _Py_Dealloc - void _Py_Dealloc(PyObject *op) {