(See bpo-40170 for more details.) (Contributed by Victor Stinner in bpo-38644 and bpo-39542.) • Removed the following functions from the C API. Call$_{PyGC_Collect()}$ explicitly to clear all free lists. (Contributed by Inada Naoki and Victor Stinner in bpo-37340, bpo-38896 and bpo-40428.) – PyAsyncGen_ClearFreeLists() • Removed _PyRuntime.getframe hook and removed _PyThreadState_GetFrame macro which was an alias to$_{_PyRuntime.getframe}$ . They were only exposed by the internal C API. Removed also PyThreadFrameGetter type. (Contributed by Victor Stinner in bpo-39946.) ∗ _Py_tracemalloc_config ∗ _Py_AddToAllObjects() (specific to$_{Py_TRACE_REFS}$ build) ∗ _Py_PrintReferenceAddresses() ∗ _Py_PrintReferences() ∗ _PyDebug_PrintTotalRefs() – Moved following functions and definitions to the internal C API: ∗ Py_TRASHCAN_SAFE_BEGIN ∗ Py_TRASHCAN_SAFE_END ∗ Py_TRASHCAN_END ∗ Py_TRASHCAN_BEGIN ∗ Py_TRASHCAN_BEGIN_CONDITION ∗ PyTrash_UNWIND_LEVEL ∗ The trashcan mechanism which never worked in the limited C API. ∗ _Py_GetRefTotal() ∗ _PyTraceMalloc_NewReference() ∗ _Py_ForgetReference() ∗ _Py_NewReference() ∗ _Py_CheckRecursionLimit ∗ PyThreadState_DeleteCurrent() (Contributed by Joannah Nanjekye in bpo-37878.) – Excluded the following functions from the limited C API: • Changes in the limited C API (if$_{Py_LIMITED_API}$ macro is defined): • The tp_print slot of PyTypeObject has been removed. It was used for printing objects to files in Python 2.7 and before. Since Python 3.0, it has been ignored and unused. (Contributed by Jeroen Demeyer in bpo-36974.) • Excluded $_{PyFPE_START_PROTECT()}$and PyFPE_END_PROTECT() macros of $_{pyfpe.h}$from the limited C API. (Contributed by Victor Stinner in bpo-38835.) 12.3 Removed – PyIndex_Check() is now always declared as an opaque function to hide implementation details: removed the PyIndex_Check() macro. The macro accessed directly the PyTypeObject. tp_as_number member. – PyObject_CheckBuffer() macro was converted to a function: the macro accessed directly the PyTypeObject.tp_as_buffer member. – $_{PyObject_GET_WEAKREFS_LISTPTR()}$macro was converted to a function: the macro accessed directly the PyTypeObject.tp_weaklistoffset member. 21