Closed huynhphan89 closed 9 years ago
Global variable (and constants) plus static members of classes/structs/enums with inital values basically initialised with the same dispatch once guarantees. And you can let the inital value be the result of a closure if you need any complex set up.
@huynhphan89 What @josephlord said. If you have a specific use of dispatch_once
in Swift, feel free to share :)
Hi,
You said "I've found no need for dispatch_once in Swift" in #2 . Could you please explain why no need to use dispatch_one in Swift?
Thanks.