Skip to content

Conversation

@hauntsaninja
Copy link
Collaborator

No description provided.

@github-actions

This comment has been minimized.

def __or__(self, __value: Any) -> types.UnionType: ...
def __ror__(self, __value: Any) -> types.UnionType: ...
if sys.version_info >= (3, 12):
__type_params__: tuple[object, ...]
Copy link
Member

Choose a reason for hiding this comment

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

This also needs to be added to builtins.function and types.FunctionType

Copy link
Member

Choose a reason for hiding this comment

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

And we can ideally type it as tuple[TypeVar | ParamSpec | TypeVarTuple, ...], though it's possible some type checkers will get upset.

Copy link
Member

Choose a reason for hiding this comment

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

And we can ideally type it as tuple[TypeVar | ParamSpec | TypeVarTuple, ...], though it's possible some type checkers will get upset.

To my surprise, it looks like they're all okay with it!

@AlexWaygood AlexWaygood requested a review from JelleZijlstra June 2, 2023 12:30
@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2023

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@AlexWaygood AlexWaygood merged commit be85cc7 into python:main Jun 4, 2023
@hauntsaninja hauntsaninja deleted the builtins branch June 4, 2023 04:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants