Sendable & BindingAction protocol #1938
-
Hi, everybody!
State Code:
Warning: |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hey @Alex0Klain! Because diagnostics were unreliable, the library is not quite yet committed regarding sendability requirements, and changes were postponed to a later time, but these changes are imminent if Xcode 14.3 enables sendability checks by default. |
Beta Was this translation helpful? Give feedback.
-
@Alex0Klain Also, if you are encountering some of these issues in the new Xcode beta, it appears that the sendability checking was accidentally made more strict by default, and will be made more lenient again soon: swiftlang/swift#63786 |
Beta Was this translation helpful? Give feedback.
Hey @Alex0Klain! Because diagnostics were unreliable, the library is not quite yet committed regarding sendability requirements, and changes were postponed to a later time, but these changes are imminent if Xcode 14.3 enables sendability checks by default.
In the meantime, you can import
ComposableArchitecture
like@preconcurrency import ComposableArchitecture
and the warning will go away (I think that you can even narrow to@preconcurrency import ComposableArchitecture.BindingAction
if you want to preserve concurrency warnings for other parts of the library). Your code is fine and the correct way to conform toSendable
.When
BindingAction
will be sendable (it'll very likely be), you'll g…