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 db9380f commit 2db6293Copy full SHA for 2db6293
lib/Sema/CSApply.cpp
@@ -166,8 +166,14 @@ ConcreteDeclRef findNamedWitnessImpl(
166
167
// For a type with dependent conformance, just return the requirement from
168
// the protocol. There are no protocol conformance tables.
169
- if (!conformance->isConcrete())
170
- return requirement;
+ if (!conformance->isConcrete()) {
+ auto subMap = SubstitutionMap::getProtocolSubstitutions(proto, type,
171
+ *conformance);
172
+ SmallVector<Substitution, 2> subs;
173
+ proto->getGenericSignature()->getSubstitutions(subMap, subs);
174
+ return ConcreteDeclRef(tc.Context, requirement, subs);
175
+ }
176
+
177
auto concrete = conformance->getConcrete();
178
return concrete->getWitnessDeclRef(requirement, &tc);
179
}
0 commit comments