Skip to content

Commit e7d9d00

Browse files
committed
Sema: Remove a bit of dead code from CSApply
1 parent 37ac1a0 commit e7d9d00

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

lib/Sema/CSApply.cpp

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1347,8 +1347,6 @@ namespace {
13471347
}
13481348

13491349
// Figure out the index and result types.
1350-
auto containerTy
1351-
= subscript->getDeclContext()->getDeclaredTypeOfContext();
13521350
auto subscriptTy = simplifyType(selected->openedType);
13531351
auto indexTy = subscriptTy->castTo<AnyFunctionType>()->getInput();
13541352
auto resultTy = subscriptTy->castTo<AnyFunctionType>()->getResult();
@@ -1362,7 +1360,6 @@ namespace {
13621360
if (knownOpened != solution.OpenedExistentialTypes.end()) {
13631361
base = openExistentialReference(base, knownOpened->second, subscript);
13641362
baseTy = knownOpened->second;
1365-
containerTy = baseTy;
13661363
}
13671364

13681365
// Coerce the index argument.
@@ -1407,7 +1404,7 @@ namespace {
14071404
// Convert the base.
14081405
auto openedFullFnType = selected->openedFullType->castTo<FunctionType>();
14091406
auto openedBaseType = openedFullFnType->getInput();
1410-
containerTy = solution.simplifyType(openedBaseType);
1407+
auto containerTy = solution.simplifyType(openedBaseType);
14111408
base = coerceObjectArgumentToType(
14121409
base, containerTy, subscript, AccessSemantics::Ordinary,
14131410
locator.withPathElement(ConstraintLocator::MemberRefBase));

0 commit comments

Comments
 (0)