]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-44872: use new trashcan macros in framobject.c (GH-27683) (GH-27690)
authorIrit Katriel <1055913+iritkatriel@users.noreply.github.com>
Tue, 10 Aug 2021 07:56:14 +0000 (08:56 +0100)
committerGitHub <noreply@github.com>
Tue, 10 Aug 2021 07:56:14 +0000 (09:56 +0200)
Misc/NEWS.d/next/Core and Builtins/2021-08-09-16-16-03.bpo-44872.OKRlhK.rst [new file with mode: 0644]
Objects/frameobject.c

diff --git a/Misc/NEWS.d/next/Core and Builtins/2021-08-09-16-16-03.bpo-44872.OKRlhK.rst b/Misc/NEWS.d/next/Core and Builtins/2021-08-09-16-16-03.bpo-44872.OKRlhK.rst
new file mode 100644 (file)
index 0000000..9a0d000
--- /dev/null
@@ -0,0 +1 @@
+Use new trashcan macros (Py_TRASHCAN_BEGIN/END) in frameobject.c instead of the old ones (Py_TRASHCAN_SAFE_BEGIN/END).
\ No newline at end of file
index 034b908ade31cce6887e8040830cf69339eb7ce8..aa973016aefeacc4bd496b5e79c10837c53da88f 100644 (file)
@@ -581,7 +581,7 @@ frame_dealloc(PyFrameObject *f)
         _PyObject_GC_UNTRACK(f);
     }
 
-    Py_TRASHCAN_SAFE_BEGIN(f)
+    Py_TRASHCAN_BEGIN(f, frame_dealloc);
     /* Kill all local variables */
     PyObject **valuestack = f->f_valuestack;
     for (PyObject **p = f->f_localsplus; p < valuestack; p++) {
@@ -621,7 +621,7 @@ frame_dealloc(PyFrameObject *f)
     }
 
     Py_DECREF(co);
-    Py_TRASHCAN_SAFE_END(f)
+    Py_TRASHCAN_END;
 }
 
 static inline Py_ssize_t