Skip to content

Commit f5e40fe

Browse files
committed
Eliminate another unnecessary use of an archetype's generic environment
1 parent 2140dc2 commit f5e40fe

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/Sema/CSSimplify.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8808,8 +8808,8 @@ ConstraintSystem::SolutionKind ConstraintSystem::simplifyMemberConstraint(
88088808
baseTy->getMetatypeInstanceType()->getAs<ArchetypeType>()) {
88098809
if (auto genericTy =
88108810
archetype->mapTypeOutOfContext()->getAs<GenericTypeParamType>()) {
8811-
for (auto param :
8812-
archetype->getGenericEnvironment()->getGenericParams()) {
8811+
for (auto param : DC->getGenericSignatureOfContext()
8812+
.getGenericParams()) {
88138813
// Find a param at the same depth and one index past the type we're
88148814
// dealing with
88158815
if (param->getDepth() != genericTy->getDepth() ||

0 commit comments

Comments
 (0)