From cef542ca572fdd402ff0e10093a0c1b459e5dcd6 Mon Sep 17 00:00:00 2001 From: Alex Waygood Date: Tue, 25 Apr 2023 10:24:49 -0600 Subject: [PATCH] gh-103721: Improve cross-references for generic-alias docs (#103838) Cc. @adriangb The "stub documentation" in `types.rst` does already link to the in-depth docs in `stdtypes.rst`, but the link isn't obvious for new users. It deserves to be made more prominent. - Issue: https://github.com/python/cpython/issues/103721 --- Doc/library/types.rst | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Doc/library/types.rst b/Doc/library/types.rst index 54887f4c519..a15fb5cfa49 100644 --- a/Doc/library/types.rst +++ b/Doc/library/types.rst @@ -351,6 +351,13 @@ Standard names are defined for the following types: .. versionchanged:: 3.9.2 This type can now be subclassed. + .. seealso:: + + :ref:`Generic Alias Types` + In-depth documentation on instances of :class:`!types.GenericAlias` + + :pep:`585` - Type Hinting Generics In Standard Collections + Introducing the :class:`!types.GenericAlias` class .. class:: UnionType