We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 915ae67 commit 48ca87dCopy full SHA for 48ca87d
lib/AST/RequirementMachine/RequirementLowering.cpp
@@ -281,10 +281,7 @@ struct InferRequirementsWalker : public TypeWalker {
281
auto addSameTypeConstraint = [&](Type firstType,
282
AssociatedTypeDecl *assocType) {
283
auto *protocol = assocType->getProtocol();
284
- auto *module = protocol->getParentModule();
285
- auto conf = module->lookupConformance(firstType, protocol);
286
- auto secondType = conf.getAssociatedType(
287
- firstType, assocType->getDeclaredInterfaceType());
+ auto secondType = lookupMemberType(firstType, protocol, assocType);
288
Requirement req(RequirementKind::SameType, firstType, secondType);
289
desugarRequirement(req, reqs);
290
};
0 commit comments