Skip to content

[CS] A couple of ExprPattern conjunction fixes #66565

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

Merged
merged 2 commits into from
Jun 13, 2023

Conversation

hamishknight
Copy link
Contributor

  • Make sure to walk patterns when collecting type variables for closure constraint
  • Make sure to walk ExprPattern conjunction elements the same way we walk other conjunction elements to allow e.g property wrapper projections to work correctly

rdar://110617471
rdar://110649179
Resolves #66561

Previously we would skip over ExprPatterns, but
we need to ensure that we walk them, as they may
have interesting variable references that the
closure needs to be connected to the type
variables for.

rdar://110617471
Apply the same logic that we apply to other
conjunction elements, to make sure that e.g
property wrapper projected values work correctly.

rdar://110649179
@hamishknight
Copy link
Contributor Author

@swift-ci please test

@hamishknight
Copy link
Contributor Author

@swift-ci please test source compatibility

@hamishknight hamishknight merged commit 762cd4d into swiftlang:main Jun 13, 2023
@hamishknight hamishknight deleted the connect-two branch June 13, 2023 09:08
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.

Property wrapper on local variable cannot be used with its projected value in ExprPattern
2 participants