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

Remove python_version from lowered marker representation #9343

Open
wants to merge 1 commit into
base: charlie/lower-i
Choose a base branch
from

Conversation

charliermarsh
Copy link
Member

Summary

We never construct these -- they should be impossible, since we always translate to python_full_version. This PR encodes that impossibility in the types.

MarkerTreeKind::True => true,
MarkerTreeKind::False => false,
MarkerTreeKind::Version(marker) => marker.edges().any(|(range, tree)| {
if marker.key() == LoweredMarkerValueVersion::PythonVersion {
Copy link
Member Author

Choose a reason for hiding this comment

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

An example of why this is important: I think this was just straight-up wrong? (But it's unused.)

@charliermarsh charliermarsh added the internal A refactor or improvement that is not user-facing label Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal A refactor or improvement that is not user-facing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant