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

Resolve concurrency check warning on Swift 5.10 #522

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

LiYanan2004
Copy link
Contributor

Swift 5.10 introduces stricter concurrency check which adds one more warning Reference to captured var 'progress' in concurrently-executing code; this is an error in Swift 6.

Because progress update is based on Notification and operates on OperationQueue.main, so we don't need to worry about data races.

So I opt-out concurrency check here by using nonisolated(unsafe)

@MattKiazyk
Copy link
Contributor

@LiYanan2004 can you clean up this PR so it just includes the concurrency check since the other change was already merged in via #521

@LiYanan2004
Copy link
Contributor Author

@MattKiazyk Hi, thanks for mentioning this. It's my fault. I have cleaned the PR to only contains swift-5.10 concurrency fix.

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.

None yet

2 participants