Skip to content

[6.0][Sema]: improve noasync diagnostics in defer statement bodies #73921

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 1 commit into from
May 27, 2024

Conversation

jamieQ
Copy link
Contributor

@jamieQ jamieQ commented May 27, 2024

updates noasync diagnostics in TypeCheckAvailability.cpp to diagnose
defer bodies as if they had the same `isAsyncContext()` value as their
nearest non-defer parent scope.

resolves: swiftlang#73614
(cherry picked from commit e68c36b)
@jamieQ jamieQ marked this pull request as ready for review May 27, 2024 02:05
@jamieQ jamieQ requested a review from a team as a code owner May 27, 2024 02:05
@jamieQ
Copy link
Contributor Author

jamieQ commented May 27, 2024

@tshortli as requested, here is a PR re-targeting the 6.0 release branch

@tshortli
Copy link
Contributor

Thanks, @jamieQ! I supplied the template for release/6.0 contributions, feel free to add or adjust.

@tshortli
Copy link
Contributor

@swift-ci please test

@tshortli tshortli requested a review from hborla May 27, 2024 02:18
@hborla hborla merged commit fde2f5c into swiftlang:release/6.0 May 27, 2024
5 checks passed
@jamieQ jamieQ deleted the diagnose-noasync-in-defer-6.0 branch May 28, 2024 12:37
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.

3 participants