mirror of
https://github.com/python/cpython.git
synced 2025-09-27 10:50:04 +00:00
As suggested by Toby Dickenson, setting ob_type to NULL in
_Py_Dealloc(), is a bad idea (and always was!). So let's drop it.
This commit is contained in:
parent
1bf4e93180
commit
1e3c8ccb9b
1 changed files with 0 additions and 4 deletions
|
@ -978,10 +978,6 @@ _Py_Dealloc(PyObject *op)
|
||||||
{
|
{
|
||||||
destructor dealloc = op->ob_type->tp_dealloc;
|
destructor dealloc = op->ob_type->tp_dealloc;
|
||||||
_Py_ForgetReference(op);
|
_Py_ForgetReference(op);
|
||||||
#ifndef WITH_CYCLE_GC
|
|
||||||
if (_PyTrash_delete_nesting < PyTrash_UNWIND_LEVEL-1)
|
|
||||||
op->ob_type = NULL;
|
|
||||||
#endif
|
|
||||||
(*dealloc)(op);
|
(*dealloc)(op);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue