Skip to content

Commit 3bfc997

Browse files
committed
Sema: Replace a usage of ArchetypeType::getExistentialType() with something cheaper
1 parent f632363 commit 3bfc997

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/Sema/CSApply.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,8 @@ static bool isOpenedAnyObject(Type type) {
7676
if (!archetype || !archetype->isRoot())
7777
return false;
7878

79-
return archetype->getExistentialType()->isAnyObject();
79+
return (archetype->requiresClass() &&
80+
!archetype->hasRequirements());
8081
}
8182

8283
SubstitutionMap

0 commit comments

Comments
 (0)