diff options
author | kj <28750310+Fidget-Spinner@users.noreply.github.com> | 2020-10-30 12:01:17 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-29 21:01:17 -0700 |
commit | 9129af6050b747f288baa9d4e7d43031647ed222 (patch) | |
tree | e000a5bbdc28fd11d280dd807b5fd7f4946576e9 /Doc/reference/expressions.rst | |
parent | bpo-42061: Document __format__ for IP addresses (GH-23018) (diff) | |
download | cpython-9129af6050b747f288baa9d4e7d43031647ed222.tar.gz cpython-9129af6050b747f288baa9d4e7d43031647ed222.tar.bz2 cpython-9129af6050b747f288baa9d4e7d43031647ed222.zip |
bpo-42198: Link to GenericAlias in typing and expressions (GH-23030)
Follow up to 7cdf30fff39ea97f403b5472096349998d190e30 and 4173320920706b49a004bdddd8d7108e8984e3fc. This addresses the point "1. Update links in typing, subscription and union to point to GenericAlias." in the bpo for this PR.
Diffstat (limited to 'Doc/reference/expressions.rst')
-rw-r--r-- | Doc/reference/expressions.rst | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst index 938a9732f5a..512aa5af956 100644 --- a/Doc/reference/expressions.rst +++ b/Doc/reference/expressions.rst @@ -837,14 +837,8 @@ this method will need to explicitly add that support. A string's items are characters. A character is not a separate data type but a string of exactly one character. -.. - At the time of writing this, there is no documentation for generic alias - or PEP 585. Thus the link currently points to PEP 585 itself. - Please change the link for generic alias to reference the correct - documentation once documentation for PEP 585 becomes available. - Subscription of certain :term:`classes <class>` or :term:`types <type>` -creates a `generic alias <https://www.python.org/dev/peps/pep-0585/>`_. +creates a :ref:`generic alias <types-genericalias>`. In this case, user-defined classes can support subscription by providing a :meth:`__class_getitem__` classmethod. |