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

[Config] Conditionally mark closures as Sendable for Xcode 16 #14314

Merged
merged 4 commits into from
Jan 7, 2025
Merged

Conversation

ncooke3
Copy link
Member

@ncooke3 ncooke3 commented Jan 7, 2025

I downloaded last Xcode 15 version, Xcode 15.4, to test and found that adding Sendable to the closure params created a warning when the call site inherited an isolation domain (main actor, global actor, etc.). The warning is more disruptive to Xcode 15 users since Xcode 15 does not include Swift 6 language version.

In Xcode 16, the same warning appears for Swift 5 users and is an error in Swift 6.

Screenshot 2025-01-07 at 3 29 19 PM

Conclusion– no new warnings for Xcode 15. New warnings for Xcode 16 where newly Sendable completion handler will warn about changing properties belonging to other isolation domains (see screenshot). New warnings are errors in Swift 6 mode in Xcode 16.

Fixes #14257

@ncooke3 ncooke3 changed the title Nc/14257 [Config] Conditionally mark closures as Sendable for Xcode 16 Jan 7, 2025
@ncooke3 ncooke3 requested a review from paulb777 January 7, 2025 20:27
@ncooke3 ncooke3 modified the milestones: 11.8.0 - M159, 11.7.0 - M158 Jan 7, 2025
@ncooke3 ncooke3 merged commit f94a964 into main Jan 7, 2025
38 checks passed
@ncooke3 ncooke3 deleted the nc/14257 branch January 7, 2025 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remote Config's addOnConfigUpdateListener crashing with Swift 6 set as Swift Language Version
3 participants