mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Executors] Remote distributed actors get "crash on enqueue" default executor (#64969)
This commit is contained in:
committed by
GitHub
parent
8d709c4e80
commit
b666fc672e
@@ -9648,29 +9648,6 @@ const VarDecl *ClassDecl::getUnownedExecutorProperty() const {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
const VarDecl *ClassDecl::getLocalUnownedExecutorProperty() const {
|
||||
auto &C = getASTContext();
|
||||
|
||||
if (!isDistributedActor())
|
||||
return nullptr;
|
||||
|
||||
llvm::SmallVector<ValueDecl *, 2> results;
|
||||
this->lookupQualified(getSelfNominalTypeDecl(),
|
||||
DeclNameRef(C.Id_localUnownedExecutor),
|
||||
NL_ProtocolMembers,
|
||||
results);
|
||||
|
||||
for (auto candidate: results) {
|
||||
if (isa<ProtocolDecl>(candidate->getDeclContext()))
|
||||
continue;
|
||||
|
||||
if (VarDecl *var = dyn_cast<VarDecl>(candidate))
|
||||
return var;
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
bool ClassDecl::isRootDefaultActor() const {
|
||||
return isRootDefaultActor(getModuleContext(), ResilienceExpansion::Maximal);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user