Skip to content

is_singleton_type: move business logic to type definitions #13165

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 17, 2022

Conversation

vlaci
Copy link
Contributor

@vlaci vlaci commented Jul 17, 2022

This greatly reduces complexity as each type can determine for
themselves if they are representing a singleton.

get_enum_values has to be moved as well, as it is used by
get_singleton_type.

Relates-to: #13117

This greatly reduces complexity as each type can determine for
themselves if they are representing a singleton.

`get_enum_values` has to be moved as well, as it is used by
`get_singleton_type`.

Relates-to: python#13117
@github-actions
Copy link
Contributor

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

Copy link
Member

@ilevkivskyi ilevkivskyi left a comment

Choose a reason for hiding this comment

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

LGTM

@ilevkivskyi ilevkivskyi merged commit 35d9aef into python:master Jul 17, 2022
@vlaci vlaci deleted the is_singleton_type branch July 17, 2022 11:33
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.

2 participants