8000 Add main actor isolation for Swift Concurrency by jhoerr-livefront · Pull Request #37 · livefront/duvet · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add main actor isolation for Swift Concurrency #37

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

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

jhoerr-livefront
Copy link

Adds @MainActor isolation to protocols and structs that don't already have it. In projects adopting Swift Concurrency that use Duvet, attempting to conform a main actor-isolated class to one of Duvet's protocols that is not explicitly marked as main actor-isolated will result in the following warning (and future error):

Main actor-isolated instance method 'dism 8000 issSheetViewController()' cannot be used to satisfy nonisolated requirement from protocol 'SheetViewControllerDelegate'; this is an error in the Swift 6 language mode

I've added a few more @MainActors to other protocols (etc) as well as the test cases in order to avoid other potential issues, even though the only one we're resolving on Box Tops is with SheetViewControllerDelegate.

@nathan-livefront nathan-livefront force-pushed the fix/swift-concurrency-main-actor branch from 9badd0b to e442141 Compare June 20, 2025 22:14
@jhoerr-livefront
Copy link
Author

I can't approve my own PR, but your changes look good @nathan-livefront

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.

2 participants
0