]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.12] gh-123570: Add link to `weakref.ref` from `weakref_slot` docs in `dataclasses...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Mon, 2 Sep 2024 07:05:18 +0000 (09:05 +0200)
committerGitHub <noreply@github.com>
Mon, 2 Sep 2024 07:05:18 +0000 (07:05 +0000)
gh-123570: Add link to `weakref.ref` from `weakref_slot` docs in `dataclasses` (GH-123571)
(cherry picked from commit c3ed775899eedd47d37f8f1840345b108920e400)

Co-authored-by: sobolevn <mail@sobolevn.me>
Doc/library/dataclasses.rst

index 8f7b19755591cbfe10881b673bda4d4e52a93864..87c8725dd83c0994264c13d6d3c7686356dd8c30 100644 (file)
@@ -215,7 +215,8 @@ Module contents
 
    - *weakref_slot*: If true (the default is ``False``), add a slot
      named "__weakref__", which is required to make an instance
-     weakref-able.  It is an error to specify ``weakref_slot=True``
+     :func:`weakref-able <weakref.ref>`.
+     It is an error to specify ``weakref_slot=True``
      without also specifying ``slots=True``.
 
     .. versionadded:: 3.11