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
🍒[5.7][Distributed] Fix too restrictive distributed witness isolation checking (#59397)
* [Distributed] Implement missing case in permitting witnesses
* improve FIXME to link to issue
* workaround for #59356 while still implementing the witness feature
* [Distributed] Further witness checking cleanup and tests
func send<Message:Codable>(message:Message)throws->String{""}// expected-warning{{non-sendable type 'Message' in parameter of actor-isolated instance method 'send(message:)' satisfying protocol requirement cannot cross actor boundary}}
137
+
func send<Message:Codable&Sendable>(message:Message)throws->String{""} // OK
131
138
}
132
139
133
140
protocolAsyncThrowsAll{
@@ -139,9 +146,15 @@ actor LocalOK_AsyncThrowsAll: AsyncThrowsAll {
da.terminated(da:"the terminated func is not distributed") // expected-error{{only 'distributed' instance methods can be called on a potentially remote distributed actor}}
tryawait da.terminated(da:"the terminated func is not distributed")
223
+
// expected-error@-1{{only 'distributed' instance methods can be called on a potentially remote distributed actor}}
224
+
// expected-warning@-2{{no calls to throwing functions occur within 'try' expression}}
225
+
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
tryawait wda.terminated(da:"the terminated func is not distributed")
237
+
// expected-error@-1{{only 'distributed' instance methods can be called on a potentially remote distributed actor}}
238
+
// expected-warning@-2{{no calls to throwing functions occur within 'try' expression}}
239
+
240
+
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
0 commit comments