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

Keep track of relevant axes when descending in normalize #3670

Merged
merged 2 commits into from
Mar 10, 2025

Conversation

glittershark
Copy link
Member

When we descend through types in normalize, we need to keep track of a successive intersection of which axes we actually care about (eg if some are skipped because of modalities). This adds a new relevant_axes argument to loop which tracks that, and only does the join along the intersection of those relevant axes and the relevant axes in the type_info.

This fixes a bug where we didn't actually mode cross when a type which doesn't normally mode cross along that axis was nested inside a modality which should have allowed crossing.

When we descend through types in normalize, we need to keep track of a
successive intersection of which axes we actually care about (eg if some are
skipped because of modalities). This adds a new `relevant_axes` argument to loop
which tracks that, and only does the join along the intersection of those
relevant axes and the relevant axes in the type_info.

This fixes a bug where we didn't actually mode cross when a type which doesn't
normally mode cross along that axis was nested inside a modality which should
have allowed crossing.
@glittershark glittershark added typing modes Work on modes. There's some overlap with the `multicore` label, but not strictly so. labels Mar 7, 2025
@glittershark glittershark requested a review from goldfirere March 7, 2025 19:19
@glittershark glittershark merged commit 6ba2457 into main Mar 10, 2025
22 checks passed
@glittershark glittershark deleted the aspsmith/track-relevant-axes-in-normalize-loop branch March 10, 2025 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
modes Work on modes. There's some overlap with the `multicore` label, but not strictly so. typing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants