From 5e8b835bef47f06109f54377d618bf44bb03af1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bern=C3=A1t=20G=C3=A1bor?= Date: Sun, 31 May 2026 10:08:05 -0700 Subject: [PATCH] gh-89554: Document weakref type objects as classes ReferenceType, ProxyType and CallableProxyType are classes (the type objects for weak references and proxies), but were documented with the ".. data::" directive, so ":class:" cross-references to them cannot resolve against a py:class target. Switch these three entries to ".. class::". ProxyTypes is left as ".. data::" since it is a sequence of the proxy type objects, not a type itself. --- Doc/library/weakref.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/library/weakref.rst b/Doc/library/weakref.rst index 87dd860da4dcc46..318da931fc314cd 100644 --- a/Doc/library/weakref.rst +++ b/Doc/library/weakref.rst @@ -324,17 +324,17 @@ same issues as the :meth:`WeakKeyDictionary.keyrefs` method. .. versionadded:: 3.4 -.. data:: ReferenceType +.. class:: ReferenceType The type object for weak references objects. -.. data:: ProxyType +.. class:: ProxyType The type object for proxies of objects which are not callable. -.. data:: CallableProxyType +.. class:: CallableProxyType The type object for proxies of callable objects.