]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Also count UNREF's as freeing an object (only relevant when
authorSjoerd Mullender <sjoerd@acm.org>
Thu, 6 Apr 1995 13:47:48 +0000 (13:47 +0000)
committerSjoerd Mullender <sjoerd@acm.org>
Thu, 6 Apr 1995 13:47:48 +0000 (13:47 +0000)
COUNT_ALLOCS is defined).

Include/object.h

index 0b85fd3f4b81afb928ea8bc575ce0583b28feabd..d1e60be700a010657d3792b63cfc0a9b3e7e1bdf 100644 (file)
@@ -295,11 +295,12 @@ environment the global variable trick is not safe.)
 #ifndef Py_TRACE_REFS
 #ifdef COUNT_ALLOCS
 #define _Py_Dealloc(op) ((op)->ob_type->tp_free++, (*(op)->ob_type->tp_dealloc)((PyObject *)(op)))
+#define _Py_ForgetReference(op) ((op)->ob_type->tp_free++)
 #else
 #define _Py_Dealloc(op) (*(op)->ob_type->tp_dealloc)((PyObject *)(op))
-#endif
 #define _Py_ForgetReference(op) /*empty*/
 #endif
+#endif
 
 #ifdef COUNT_ALLOCS
 extern void inc_count Py_PROTO((PyTypeObject *));