bpo-44872: use new trashcan macros in framobject.c (GH-27683) (GH-27691)

This commit is contained in:
Irit Katriel 2021-08-10 08:55:39 +01:00 committed by GitHub
parent fcbe8c63d7
commit ede1dc416d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

@ -0,0 +1 @@
Use new trashcan macros (Py_TRASHCAN_BEGIN/END) in frameobject.c instead of the old ones (Py_TRASHCAN_SAFE_BEGIN/END).

View file

@ -575,7 +575,7 @@ frame_dealloc(PyFrameObject *f)
if (_PyObject_GC_IS_TRACKED(f))
_PyObject_GC_UNTRACK(f);
Py_TRASHCAN_SAFE_BEGIN(f)
Py_TRASHCAN_BEGIN(f, frame_dealloc);
/* Kill all local variables */
valuestack = f->f_valuestack;
for (p = f->f_localsplus; p < valuestack; p++)
@ -609,7 +609,7 @@ frame_dealloc(PyFrameObject *f)
}
Py_DECREF(co);
Py_TRASHCAN_SAFE_END(f)
Py_TRASHCAN_END;
}
static inline Py_ssize_t