@@ -233,12 +233,6 @@ void TypeChecker::validateWhereClauses(ProtocolDecl *protocol,
233
233
}
234
234
}
235
235
236
- void TypeChecker::resolveInheritedProtocols (ProtocolDecl *protocol) {
237
- for (unsigned i : indices (protocol->getInherited ()))
238
- (void )protocol->getInheritedType (i);
239
- resolveTrailingWhereClause (protocol);
240
- }
241
-
242
236
// / check the inheritance clause of a type declaration or extension thereof.
243
237
// /
244
238
// / This routine validates all of the types in the parsed inheritance clause,
@@ -3966,8 +3960,6 @@ void TypeChecker::validateDecl(ValueDecl *D) {
3966
3960
}
3967
3961
}
3968
3962
3969
- // Record inherited protocols.
3970
- resolveInheritedProtocols (proto);
3971
3963
resolveTrailingWhereClause (proto);
3972
3964
3973
3965
validateAttributes (*this , D);
@@ -4513,8 +4505,6 @@ void TypeChecker::validateDeclForNameLookup(ValueDecl *D) {
4513
4505
4514
4506
(void ) proto->getFormalAccess ();
4515
4507
4516
- // Record inherited protocols.
4517
- resolveInheritedProtocols (proto);
4518
4508
resolveTrailingWhereClause (proto);
4519
4509
4520
4510
for (auto ATD : proto->getAssociatedTypeMembers ()) {
@@ -4734,6 +4724,7 @@ static void finalizeType(TypeChecker &TC, NominalTypeDecl *nominal) {
4734
4724
// validation of protocols, but clients will assume that things
4735
4725
// like the requirement signature have been set.
4736
4726
if (auto PD = dyn_cast<ProtocolDecl>(nominal)) {
4727
+ (void )PD->getInheritedProtocols ();
4737
4728
if (!PD->isRequirementSignatureComputed ()) {
4738
4729
TC.validateDecl (PD);
4739
4730
}
0 commit comments