Instance PropertyConcurrency


    The result from a nonthrowing task, after it completes.

    • iOS 13.0+
    • macOS 10.15+
    • tvOS 13.0+
    • watchOS 6.0+
    var value: Success { get async }


    If the task hasn’t completed yet, accessing this property waits for it to complete and its priority increases to that of the current task. Note that this might not be as effective as creating the task with the correct priority, depending on the executor’s scheduling details.

    Tasks that never throw an error can still check for cancellation, but they need to use an approach like returning nil instead of throwing an error.