Store simple_destructor in tp_dealloc.
Replace the function pointer to the simple_destructor with a boolean indicating that the tp_dealloc function is safe to call whenever the simple_destructor used to be instead. A few additional classes are also specified to have a safe_tp_dealloc. For exceptions, use a hack where we look for the creation of exception classes and store them in a list so we can set their destructor at the same time as other classes.
Showing
Please register or sign in to comment