Skip to content
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

Respect hash-equivalent literals in iteration-over-set #14063

Merged
merged 1 commit into from
Nov 3, 2024

Conversation

charliermarsh
Copy link
Member

Summary

Closes #14049.

@charliermarsh charliermarsh added the bug Something isn't working label Nov 3, 2024
@charliermarsh charliermarsh marked this pull request as ready for review November 3, 2024 18:06
@charliermarsh charliermarsh force-pushed the charlie/hash-eq branch 2 times, most recently from 44402e2 to b37c449 Compare November 3, 2024 18:07
@diceroll123
Copy link
Contributor

Welcome back, HashableExpr!

@charliermarsh
Copy link
Member Author

New HashableExpr just dropped

@charliermarsh
Copy link
Member Author

Ah wait this doesn't work for tuples.

Copy link
Contributor

github-actions bot commented Nov 3, 2024

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

Formatter (stable)

✅ ecosystem check detected no format changes.

Formatter (preview)

✅ ecosystem check detected no format changes.

@charliermarsh charliermarsh enabled auto-merge (squash) November 3, 2024 18:40
@charliermarsh charliermarsh merged commit e00594e into main Nov 3, 2024
17 checks passed
@charliermarsh charliermarsh deleted the charlie/hash-eq branch November 3, 2024 18:44
charliermarsh added a commit that referenced this pull request Nov 3, 2024
## Summary

Like #14063, but ensures that we
catch cases like `{1, True}` in which the items hash to the same value
despite not being identical.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PLC0208 false positive when a set contains equal values of different types
2 participants