◐ Shell
reader mode source ↗
Skip to content

gh-91162: Disallow tuple[T][*anything]#92255

Closed
mrahtz wants to merge 3 commits into
python:mainfrom
mrahtz:subst-fixes-1
Closed

gh-91162: Disallow tuple[T][*anything]#92255
mrahtz wants to merge 3 commits into
python:mainfrom
mrahtz:subst-fixes-1

Conversation

@mrahtz

@mrahtz mrahtz commented May 3, 2022

Copy link
Copy Markdown
Contributor

We agreed in #91162 that unpacked type arguments should only be valid to generic aliases that can accept a variable number of arguments - that is, unpacked type arguments should only be valid to generic aliases with a TypeVarTuple in the type parameters.

@JelleZijlstra Could I ask you for review on this?

(This PR is based on #92249, so there are a couple of extra commits. See the latest commit for the one that's actually part of this PR. I think I should be able to effectively hide the changes from the extra commits once #92249 is merged - so we can start review on this PR now?)

@mrahtz

mrahtz commented May 3, 2022

Copy link
Copy Markdown
Contributor Author

Oops, sorry - while implementing another PR, I realised this is probably going to conflict with something else we'll need to do in typing.py. Closing for now.

@mrahtz mrahtz closed this May 3, 2022
@mrahtz

mrahtz commented May 3, 2022

Copy link
Copy Markdown
Contributor Author

Thanks for the quick review anyway Jelle :) I'll integrate those suggestions in the upcoming PR.

@mrahtz mrahtz deleted the subst-fixes-1 branch May 8, 2022 11:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants