Skip to content

Commit b61d98e

Browse files
committed
Eliminate unprincipled unsafe global actor override behavior.
1 parent f5d6620 commit b61d98e

File tree

1 file changed

+0
-25
lines changed

1 file changed

+0
-25
lines changed

lib/Sema/TypeCheckConcurrency.cpp

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3554,31 +3554,6 @@ void swift::checkOverrideActorIsolation(ValueDecl *value) {
35543554
}
35553555
}
35563556

3557-
// If the overriding declaration uses an unsafe global actor, we can do
3558-
// anything that doesn't actively conflict with the overridden isolation.
3559-
if (isolation == ActorIsolation::GlobalActorUnsafe) {
3560-
switch (overriddenIsolation) {
3561-
case ActorIsolation::Unspecified:
3562-
return;
3563-
3564-
case ActorIsolation::ActorInstance:
3565-
case ActorIsolation::DistributedActorInstance:
3566-
case ActorIsolation::Independent:
3567-
// Diagnose below.
3568-
break;
3569-
3570-
case ActorIsolation::GlobalActor:
3571-
case ActorIsolation::GlobalActorUnsafe:
3572-
// The global actors don't match; diagnose it.
3573-
if (overriddenIsolation.getGlobalActor()->isEqual(
3574-
isolation.getGlobalActor()))
3575-
return;
3576-
3577-
// Diagnose below.
3578-
break;
3579-
}
3580-
}
3581-
35823557
// Isolation mismatch. Diagnose it.
35833558
value->diagnose(
35843559
diag::actor_isolation_override_mismatch, isolation,

0 commit comments

Comments
 (0)