AST: Refine recursive property checks on type alias types

This commit is contained in:
Slava Pestov
2019-09-11 17:25:55 -04:00
parent 6a9b566517
commit b1ffa19c7b
6 changed files with 39 additions and 28 deletions

View File

@@ -4823,7 +4823,9 @@ performMemberLookup(ConstraintKind constraintKind, DeclName memberName,
// to access the type with a protocol metatype base.
} else if (instanceTy->isExistentialType() &&
isa<TypeAliasDecl>(decl) &&
!cast<TypeAliasDecl>(decl)->getInterfaceType()->hasTypeParameter()) {
!cast<TypeAliasDecl>(decl)
->getUnderlyingType()->getCanonicalType()
->hasTypeParameter()) {
/* We're OK */