Skip to content

Commit 00a1e91

Browse files
authored
Merge pull request #38097 from CodaFi/checkerboard
2 parents bbed067 + 15a552f commit 00a1e91

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

stdlib/public/Concurrency/CheckedContinuation.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -146,11 +146,11 @@ public struct CheckedContinuation<T, E: Error> {
146146
/// After `resume` enqueues the task, control is immediately returned to
147147
/// the caller. The task will continue executing when its executor is
148148
/// able to reschedule it.
149-
public func resume(returning x: __owned T) {
149+
public func resume(returning value: __owned T) {
150150
if let c: UnsafeContinuation<T, E> = canary.takeContinuation() {
151-
c.resume(returning: x)
151+
c.resume(returning: value)
152152
} else {
153-
fatalError("SWIFT TASK CONTINUATION MISUSE: \(canary.function) tried to resume its continuation more than once, returning \(x)!\n")
153+
fatalError("SWIFT TASK CONTINUATION MISUSE: \(canary.function) tried to resume its continuation more than once, returning \(value)!\n")
154154
}
155155
}
156156

@@ -166,11 +166,11 @@ public struct CheckedContinuation<T, E: Error> {
166166
/// After `resume` enqueues the task, control is immediately returned to
167167
/// the caller. The task will continue executing when its executor is
168168
/// able to reschedule it.
169-
public func resume(throwing x: __owned E) {
169+
public func resume(throwing error: __owned E) {
170170
if let c: UnsafeContinuation<T, E> = canary.takeContinuation() {
171-
c.resume(throwing: x)
171+
c.resume(throwing: error)
172172
} else {
173-
fatalError("SWIFT TASK CONTINUATION MISUSE: \(canary.function) tried to resume its continuation more than once, throwing \(x)!\n")
173+
fatalError("SWIFT TASK CONTINUATION MISUSE: \(canary.function) tried to resume its continuation more than once, throwing \(error)!\n")
174174
}
175175
}
176176
}

0 commit comments

Comments
 (0)