@@ -223,7 +223,8 @@ Optional<Type> ConcreteContraction::substTypeParameter(
223223
224224 auto conformance = ((*substBaseType)->isTypeParameter ()
225225 ? ProtocolConformanceRef (proto)
226- : module ->lookupConformance (*substBaseType, proto));
226+ : module ->lookupConformance (*substBaseType, proto,
227+ /* allowMissing=*/ true ));
227228
228229 // The base type doesn't conform, in which case the requirement remains
229230 // unsubstituted.
@@ -363,7 +364,8 @@ ConcreteContraction::substRequirement(const Requirement &req) const {
363364 auto *proto = req.getProtocolDecl ();
364365 auto *module = proto->getParentModule ();
365366 if (!substFirstType->isTypeParameter () &&
366- !module ->lookupConformance (substFirstType, proto)) {
367+ !module ->lookupConformance (substFirstType, proto,
368+ /* allowMissing=*/ true )) {
367369 // Handle the case of <T where T : P, T : C> where C is a class and
368370 // C does not conform to P by leaving the conformance requirement
369371 // unsubstituted.
@@ -664,4 +666,4 @@ bool swift::rewriting::performConcreteContraction(
664666 ConcreteContraction concreteContraction (debug);
665667 return concreteContraction.performConcreteContraction (
666668 requirements, result, errors);
667- }
669+ }
0 commit comments