Post

Replies

Boosts

Views

Activity

Comment on Protocol implementation of a MainActor delegate requires await keyword on initializer in async code
nonisolated got rid of the error in this case. For some simple cases like unit tests these protections by the swift compiler could be interpreted as barriers or creating additional work. So far swift concurrency seems great. I'm starting to look at writing new code in my app with it, but I really don't like how the @MainActor conformance from a protocol now requires await everywhere. Even for simple properties. Now methods need to be declared for setters. (ug is this java?). Thx for the tip!
Dec ’22