File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -2971,8 +2971,7 @@ BoundGenericType *KeyPathInst::getKeyPathType() const {
29712971 auto kpTy = getType ();
29722972
29732973 if (auto existential = kpTy.getAs <ExistentialType>()) {
2974- auto containedTy = existential->getConstraintType ();
2975- return containedTy->getExistentialLayout ()
2974+ return existential->getExistentialLayout ()
29762975 .explicitSuperclass ->castTo <BoundGenericType>();
29772976 }
29782977
Original file line number Diff line number Diff line change @@ -5010,8 +5010,7 @@ namespace {
50105010 leafTy = fnTy->getResult ();
50115011 isFunctionType = true ;
50125012 } else if (auto *existential = exprType->getAs <ExistentialType>()) {
5013- auto constrainedTy = existential->getConstraintType ();
5014- auto layout = constrainedTy->getExistentialLayout ();
5013+ auto layout = existential->getExistentialLayout ();
50155014 auto keyPathTy = layout.explicitSuperclass ->castTo <BoundGenericType>();
50165015 baseTy = keyPathTy->getGenericArgs ()[0 ];
50175016 leafTy = keyPathTy->getGenericArgs ()[1 ];
You can’t perform that action at this time.
0 commit comments