https://github.com/python/cpython/commit/3cef7801dd496f002622c77a223ab210047f3fcd commit: 3cef7801dd496f002622c77a223ab210047f3fcd branch: 3.14 author: Miss Islington (bot) <[email protected]> committer: picnixz <[email protected]> date: 2025-10-13T11:30:27Z summary:
[3.14] gh-107073: fix relevant typo in `PyObject_ClearManagedDict` (GH-140032) (#140033) gh-107073: fix relevant typo in `PyObject_ClearManagedDict` (GH-140032) (cherry picked from commit 52996aaa78706e0f2a70953feaf97b474eb438e7) Co-authored-by: Mikhail Efimov <[email protected]> files: M Doc/c-api/object.rst M Doc/c-api/typeobj.rst diff --git a/Doc/c-api/object.rst b/Doc/c-api/object.rst index 241fbd3a4866c7..1e39505588f6fd 100644 --- a/Doc/c-api/object.rst +++ b/Doc/c-api/object.rst @@ -585,7 +585,7 @@ Object Protocol Clear the managed dictionary of *obj*. - This function must only be called in a traverse function of the type which + This function must only be called in a clear function of the type which has the :c:macro:`Py_TPFLAGS_MANAGED_DICT` flag set. .. versionadded:: 3.13 diff --git a/Doc/c-api/typeobj.rst b/Doc/c-api/typeobj.rst index 060d6f60174b41..d86b3ed730a3d1 100644 --- a/Doc/c-api/typeobj.rst +++ b/Doc/c-api/typeobj.rst @@ -1691,7 +1691,7 @@ and :c:data:`PyType_Type` effectively act as defaults.) :c:func:`Py_CLEAR` macro performs the operations in a safe order. If the :c:macro:`Py_TPFLAGS_MANAGED_DICT` bit is set in the - :c:member:`~PyTypeObject.tp_flags` field, the traverse function must call + :c:member:`~PyTypeObject.tp_flags` field, the clear function must call :c:func:`PyObject_ClearManagedDict` like this:: PyObject_ClearManagedDict((PyObject*)self); _______________________________________________ Python-checkins mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3//lists/python-checkins.python.org Member address: [email protected]
