Does Swift provide such shorthand/sugar syntax for commonly used thread synchronization?
Does Swift provide something like
@synchronized
in objc?
Yes, although the details are very different. In Swift concurrency, the role of @synchronized
is subsumed by actors. There is a bunch of info available on this topic. You can find my specific recommendations in the Concurrency Resources post.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"