@@ -4222,7 +4222,7 @@ ConstraintSystem::matchExistentialTypes(Type type1, Type type2,
42224222
42234223 // Finally, check parameterized protocol requirements.
42244224 if (!layout.getParameterizedProtocols().empty()) {
4225- SmallVector<std::pair<AssociatedTypeDecl * , Type>, 4> fromReqs;
4225+ SmallVector<std::pair<Identifier , Type>, 4> fromReqs;
42264226
42274227 if (type1->isExistentialType()) {
42284228 auto fromLayout = type1->getExistentialLayout();
@@ -4233,8 +4233,7 @@ ConstraintSystem::matchExistentialTypes(Type type1, Type type2,
42334233
42344234 for (unsigned i : indices(argTypes)) {
42354235 auto argType = argTypes[i];
4236- auto *assocType = assocTypes[i]->getAssociatedTypeAnchor();
4237- fromReqs.push_back(std::make_pair(assocType, argType));
4236+ fromReqs.push_back(std::make_pair(assocTypes[i]->getName(), argType));
42384237 }
42394238 }
42404239 }
@@ -4249,10 +4248,9 @@ ConstraintSystem::matchExistentialTypes(Type type1, Type type2,
42494248
42504249 for (unsigned i : indices(argTypes)) {
42514250 auto argType = argTypes[i];
4252- auto *assocType = assocTypes[i]->getAssociatedTypeAnchor();
42534251 bool found = false;
42544252 for (auto fromReq : fromReqs) {
4255- if (fromReq.first == assocType ) {
4253+ if (fromReq.first == assocTypes[i]->getName() ) {
42564254 // FIXME: Extend the locator path to point to the argument
42574255 // inducing the requirement.
42584256 auto result = matchTypes(fromReq.second, argType,
0 commit comments