Description
Describe the bug
I have played around a little with Xcode 14.0 beta 3 (I currently cannot check beta 4) and have noticed that the behavior regarding RemoteCallArgument does not match the documentation. For these functions, the properties are currently filled as follows:
// label: "a", name: "a", effectiveLabel: "a"
distributed func callMe(a: String) {}
// label: "b", name: "c", effectiveLabel: "b"
distributed func callMe(b c: String) {}
// label: nil, name: "d", effectiveLabel: "d"
distributed func callMe(_ d: String) {}
As per the documentation, in the first case, label
should be nil
.
I think, the behavior as currently implemented makes much more sense. However, effectiveLabel
is now pretty superfluous and returns the wrong string in the third case.
Steps To Reproduce
Define the following distributed actor:
distributed actor TestActor {
typealias ActorSystem = /* An actor system */
init(actorSystem: ActorSystem) {
self.actorSystem = actorSystem
}
// label: "a", name: "a", effectiveLabel: "a"
distributed func callMe(a: String) {}
// label: "b", name: "c", effectiveLabel: "b"
distributed func callMe(b c: String) {}
// label: nil, name: "d", effectiveLabel: "d"
distributed func callMe(_ d: String) {}
}
Then call each of the distributed methods on an actor proxy. This causes recordArgument()
to be called on the distributed actor system with the RemoteCallArgument
properties indicated above.
Expected behavior
As per the documentation, in the first case, label
should be nil.
Environment
- OS: macOS 12.4 running iOS 16 Simulator
- Xcode Version: 14.0 beta 3