Skip to content

Commit 9bdd7db

Browse files
committed
Eliminate a null pointer dereference
1 parent 11976c5 commit 9bdd7db

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/Sema/CSApply.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6560,7 +6560,8 @@ ArgumentList *ExprRewriter::coerceCallArguments(
65606560
cs.getConstraintLocator(argLoc));
65616561
if (knownOpened != solution.OpenedExistentialTypes.end()) {
65626562
argExpr = openExistentialReference(
6563-
argExpr, knownOpened->second, callee.getDecl(), apply->getLoc());
6563+
argExpr, knownOpened->second, callee.getDecl(),
6564+
apply ? apply->getLoc() : argExpr->getLoc());
65646565
argType = cs.getType(argExpr);
65656566
}
65666567
}

0 commit comments

Comments
 (0)