We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
HasIsolatedSelfRequest
1 parent c0cea20 commit 4b5c5acCopy full SHA for 4b5c5ac
lib/Sema/TypeCheckConcurrency.cpp
@@ -3918,8 +3918,13 @@ bool HasIsolatedSelfRequest::evaluate(
3918
return false;
3919
3920
// For accessors, consider the storage declaration.
3921
- if (auto accessor = dyn_cast<AccessorDecl>(value))
3922
- value = accessor->getStorage();
+ if (auto accessor = dyn_cast<AccessorDecl>(value)) {
+ // distributed thunks are accessors only in spirit and
3923
+ // should be handled as regular functions from isolation
3924
+ // perspective.
3925
+ if (!accessor->isDistributedThunk())
3926
+ value = accessor->getStorage();
3927
+ }
3928
3929
// Check whether this member can be isolated to an actor at all.
3930
auto memberIsolation = getMemberIsolationPropagation(value);
0 commit comments