Modern Concurrency
When was it introduced? It was introduced in Swift 5.5 at WWDC 2021. You can find the more comprehensive info about Modern Concurrency in Swift Concurrency Manifesto. What are actors? Actors eliminate shared mutable state and explicit synchronization through deep copying of all the data that passed to an actor to a message sent and preventing direct access to actor state. Actors are reference types. actor DatabaseManager { private var data: [String: String] = [:] func readData(key: String) -> String? { data[key] } func writeData(key: String, value: String) { data[key] = value } } What is an asynchronous function? The asynchronous function or asynchronous method can be suspended while it is partway through execution. It can pause in the middle when it’s waiting for something. ...