Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Description
Summary
This PR fixes GitHub issue #84519 by improving actor isolation diagnostic messages to show specific actor instance names instead of generic "actor-isolated" text.
Problem
When two different actor instances had conflicting isolation requirements in default arguments, the error message would show:
This was confusing because both isolations appeared identical, even though they referred to different actor instances (like
self
vsMyActor.shared
).Solution
Modified
ActorIsolation::printForDiagnostics
method inlib/AST/TypeCheckRequests.cpp
to:"'MyActor.shared'-isolated"
)self
parameter, show"'self'-isolated"
"actor-isolated"
Example
With this fix, the error message from the GitHub issue example:
Will now show:
Instead of the confusing:
Changes Made
ActorIsolation::printForDiagnostics
method to extract and display actor instance namesTesting
Resolves
Resolves #84519