Skip to content

Commit 60a9346

Browse files
committed
Perform substitution on conformances if we are supposed to substitute opaque archetypes
rdar://50413632
1 parent 6069814 commit 60a9346

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/AST/SubstitutionMap.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -472,7 +472,8 @@ SubstitutionMap SubstitutionMap::subst(TypeSubstitutionFn subs,
472472

473473
// Fast path for concrete case -- we don't need to compute substType
474474
// at all.
475-
if (conformance.isConcrete()) {
475+
if (conformance.isConcrete() &&
476+
!options.contains(SubstFlags::SubstituteOpaqueArchetypes)) {
476477
newConformances.push_back(
477478
ProtocolConformanceRef(
478479
conformance.getConcrete()->subst(subs, conformances)));

0 commit comments

Comments
 (0)