]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-94673: Add Per-Interpreter tp_weaklist for Static Builtin Types (#95302)
authorEric Snow <ericsnowcurrently@gmail.com>
Fri, 29 Jul 2022 01:23:47 +0000 (19:23 -0600)
committerGitHub <noreply@github.com>
Fri, 29 Jul 2022 01:23:47 +0000 (19:23 -0600)
commit3e7cad3bca64ab213c66e2bd41c9d1cf1d057526
treedef84e7995f73122d158470f8f178d38726a981c
parent6e44bf9558dbcaffd78b7c4fc7f6b474388b4a9a
gh-94673: Add Per-Interpreter tp_weaklist for Static Builtin Types (#95302)

* Store tp_weaklist on the interpreter state for static builtin types.

* Factor out _PyStaticType_GET_WEAKREFS_LISTPTR().

* Add _PyStaticType_ClearWeakRefs().

* Add a comment about how _PyStaticType_ClearWeakRefs() loops.

* Document the change.

* Update Doc/whatsnew/3.12.rst

* Fix a typo.
Doc/c-api/typeobj.rst
Doc/whatsnew/3.12.rst
Include/cpython/object.h
Include/internal/pycore_object.h
Include/internal/pycore_typeobject.h
Objects/typeobject.c
Objects/weakrefobject.c