-
-
Notifications
You must be signed in to change notification settings - Fork 108
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
Fix various things with Literal
#145
Conversation
A side effect of one of the changes is that equality comparisons of `Literal` | ||
objects will now raise a `TypeError` if one of the `Literal` objects being | ||
compared has a mutable parameter. (Using mutable parameters with `Literal` is | ||
not supported by PEP 586 or by any major static type checkers.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice dig against pyanalyze :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh entirely unintentional!! I can take this out if you like :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nah, it's true.
Seems like something's broken on 3.9.0. |
A result of python/cpython#19620. I'm looking at it. |
Fixes #113. Closes #144.
Backports python/cpython#23294 and python/cpython#23383, both originally by Yurii Karabas.