You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// after all: if you have async code, just call it directly, without the unsafe continuation
46
-
let _:String=Task.withUnsafeContinuation{ continuation in // expected-error{{invalid conversion from 'async' function of type '(UnsafeContinuation<String>) async -> Void' to synchronous function type '(UnsafeContinuation<String>) -> Void'}}
46
+
let _:String=withUnsafeContinuation{ continuation in // expected-error{{invalid conversion from 'async' function of type '(UnsafeContinuation<String>) async -> Void' to synchronous function type '(UnsafeContinuation<String>) -> Void'}}
47
47
lets=awaitsomeAsyncFunc() // rdar://70610141 for getting a better error message here
48
48
continuation.resume(returning: s)
49
49
}
50
50
51
-
let _:String=awaitTask.withUnsafeContinuation{ continuation in
51
+
let _:String=awaitwithUnsafeContinuation{ continuation in
52
52
continuation.resume(returning:"")
53
53
}
54
54
}
55
55
56
56
func test_unsafeThrowingContinuations()async{
57
-
let _:String=awaittryTask.withUnsafeThrowingContinuation{ continuation in
57
+
let _:String=awaittrywithUnsafeThrowingContinuation{ continuation in
58
58
continuation.resume(returning:"")
59
59
}
60
60
61
-
let _:String=awaittryTask.withUnsafeThrowingContinuation{ continuation in
61
+
let _:String=awaittrywithUnsafeThrowingContinuation{ continuation in
0 commit comments