Skip to content

Instantly share code, notes, and snippets.

@jeandavid
Created February 8, 2020 20:11
Show Gist options
  • Save jeandavid/d8df12fd06851ac3c0c8268d2f47d7ce to your computer and use it in GitHub Desktop.
Save jeandavid/d8df12fd06851ac3c0c8268d2f47d7ce to your computer and use it in GitHub Desktop.
Synchronous Operation Added to a Queue
let syncOperation = SyncOperation()
let queue = OperationQueue()
queue.addOperation(syncOperation)
print("Done")
// May output "Executing" then "Done" or "Done" then "Executing"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment