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

Handle capture variables in stripCapturing #22288

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Linyxus
Copy link
Contributor

@Linyxus Linyxus commented Jan 1, 2025

Partly fixes #22103

Given a capture set variable C defined with C <: CapSet^, TypeRef(C).stripCapturing previously does nothing, which is apparently wrong. For "normal" type variables there is not a problem since type variables are always pure, so stripping can do nothing for them. But this won't work for capture set variable.

This PR fixes this behavior by stripping capture variables like C to CapSet.

Given a capture set variable `C`, its `stripCapturing` should be just `CapSet`.
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.

Improve Subtyping and Normalization of Capture Sets
1 participant