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
@Sendablefunc f(){ // expected-warning{{actor-isolated synchronous instance method 'f()' cannot be marked as '@Sendable'}}
12
+
state =true
13
+
}
14
+
15
+
@Sendablenonisolatedfunc g(){}
16
+
17
+
@Sendablefunc fAsync()async{
18
+
state =true
19
+
}
20
+
}
21
+
22
+
@available(SwiftStdlib 5.1,*)
23
+
@MainActor@Sendablefunc globalActorFunc(){} // expected-warning{{main actor-isolated synchronous global function 'globalActorFunc()' cannot be marked as '@Sendable'}}
// expected-warning@-2{{no calls to throwing functions occur within 'try' expression}}
225
225
226
226
let__secretlyKnownToBeLocal= da
227
-
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK // FIXME(#59356): (the __secretlyKnown is a hack, but the whenLocal crashes now on pending isolation getting with generic actors for closures)
228
-
// FIXME: pending fix of closure isolation checking with actors #59356
229
-
// await da.whenLocal { __secretlyKnownToBeLocal in
230
-
// await __secretlyKnownToBeLocal.terminated(da: "local calls are okey!") // OK
231
-
// }
227
+
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK
228
+
await da.whenLocal{ __secretlyKnownToBeLocal in
229
+
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK
// expected-warning@-2{{no calls to throwing functions occur within 'try' expression}}
239
238
240
239
let__secretlyKnownToBeLocal= wda
241
-
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK // FIXME(#59356): (the __secretlyKnown is a hack, but the whenLocal crashes now on pending isolation getting with generic actors for closures)
242
-
// FIXME: pending fix of closure isolation checking with actors #59356
243
-
// await wda.whenLocal { __secretlyKnownToBeLocal in
244
-
// await __secretlyKnownToBeLocal.terminated(da: "local calls are okey!") // OK
245
-
// }
240
+
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK
241
+
await wda.whenLocal{ __secretlyKnownToBeLocal in
242
+
await __secretlyKnownToBeLocal.terminated(da:"local calls are okey!") // OK
0 commit comments