Skip to content

Conversation

@AlexWaygood
Copy link
Member

@AlexWaygood AlexWaygood commented Nov 3, 2021

This PR has been split off from #29335

https://bugs.python.org/issue45680

@bedevere-bot bedevere-bot added the docs Documentation in the Doc dir label Nov 3, 2021
@AlexWaygood AlexWaygood changed the title bpo-45680: typing docs: improve links to docs on GenericAlias bpo-45680: typing docs: improve links to docs on GenericAlias/__class_getitem__ Nov 3, 2021
@gvanrossum gvanrossum removed their request for review November 3, 2021 15:43
Copy link
Member

@Fidget-Spinner Fidget-Spinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly looks good to me, just one question and comment.

*Introducing* the ability to use builtin collections and ABCs as
:term:`generic types<generic type>`
*Introducing* :class:`types.GenericAlias` and the ability to use standard
library classes as :ref:`generic types<types-genericalias>`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wait, why'd the link change from the one in the glossary to about types-genericalias?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My reasoning was:

  • I think the types-genericalias link is more informative about the change that was introduced in the PEP.
  • I think it's an important piece of documentation that deserves a prominent mention near the top of the typing docs.
  • It's consistent with the link to types-union in the bullet point about PEP 604.

But I'm very happy to revert this change if you think the link to the glossary is more appropriate here 🙂

@miss-islington
Copy link
Contributor

Thanks @AlexWaygood for the PR, and @Fidget-Spinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Thanks @AlexWaygood for the PR, and @Fidget-Spinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.10.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry @AlexWaygood and @Fidget-Spinner, I had trouble checking out the 3.9 backport branch.
Please backport using cherry_picker on command line.
cherry_picker e03e50377d6f8f212af60fed4ae405ebeb73237d 3.9

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Nov 4, 2021
…/``__class_getitem__`` (pythonGH-29387)

(cherry picked from commit e03e503)

Co-authored-by: Alex Waygood <[email protected]>
@bedevere-bot
Copy link

GH-29399 is a backport of this pull request to the 3.10 branch.

@miss-islington
Copy link
Contributor

Thanks @AlexWaygood for the PR, and @Fidget-Spinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Nov 4, 2021
…/``__class_getitem__`` (pythonGH-29387)

(cherry picked from commit e03e503)

Co-authored-by: Alex Waygood <[email protected]>
@bedevere-bot
Copy link

GH-29400 is a backport of this pull request to the 3.9 branch.

miss-islington added a commit that referenced this pull request Nov 4, 2021
…/``__class_getitem__`` (GH-29387)

(cherry picked from commit e03e503)

Co-authored-by: Alex Waygood <[email protected]>
miss-islington added a commit that referenced this pull request Nov 4, 2021
…/``__class_getitem__`` (GH-29387)

(cherry picked from commit e03e503)

Co-authored-by: Alex Waygood <[email protected]>
@AlexWaygood AlexWaygood deleted the typing-docs-classgetitem-refs branch November 4, 2021 08:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants