@@ -293,8 +293,10 @@ internal func _resumeUnsafeThrowingContinuationWithError<T>(
293293
294294#endif
295295
296- /// Suspends the current task,
297- /// then calls the given closure with an unsafe continuation for the current task.
296+ /// Invokes the passed in closure and provides with an unsafe continuation for the current task.
297+ /// The body of the closure executes synchronously on the calling task, and once it returns
298+ /// the calling task is suspended. It is possible to immediately resume the task, or escape the
299+ /// continuation in order to complete it afterwards, and thus resuming the suspended task.
298300///
299301/// - Parameter fn: A closure that takes an `UnsafeContinuation` parameter.
300302/// You must resume the continuation exactly once.
@@ -311,8 +313,10 @@ public func withUnsafeContinuation<T>(
311313 }
312314}
313315
314- /// Suspends the current task,
315- /// then calls the given closure with an unsafe throwing continuation for the current task.
316+ /// Invokes the passed in closure and provides with a unsafe throwing continuation for the current task.
317+ /// The body of the closure executes synchronously on the calling task, and once it returns
318+ /// the calling task is suspended. It is possible to immediately resume the task, or escape the
319+ /// continuation in order to complete it afterwards, and thus resuming the suspended task.
316320///
317321/// - Parameter fn: A closure that takes an `UnsafeContinuation` parameter.
318322/// You must resume the continuation exactly once.
0 commit comments