[Distributed] add note explaining DefaultDistributedActorSystem

This commit is contained in:
Konrad `ktoso` Malawski
2022-03-11 11:05:56 +09:00
parent d42593a866
commit f2d60e16f2
3 changed files with 25 additions and 11 deletions

View File

@@ -0,0 +1,16 @@
// RUN: %target-swift-frontend -typecheck -verify -enable-experimental-distributed -disable-availability-checking -I %t 2>&1 %s
// UNSUPPORTED: back_deploy_concurrency
// REQUIRES: concurrency
// REQUIRES: distributed
import _Distributed
distributed actor DA {
// expected-error@-1{{distributed actor 'DA' does not declare ActorSystem it can be used with.}}
// expected-note@-3{{you can provide a module-wide default actor system by declaring:}}
// Note to add the typealias is diagnosed on the protocol:
// _Distributed.DistributedActor:3:20: note: diagnostic produced elsewhere: protocol requires nested type 'ActorSystem'; do you want to add it?
}