[CodeGen] Use preincrement version of APInt::operator++ instead of postincrement to avoid creating and immediately discarding a temporary APInt.

This is preparation for a clang change to improve the [[nodiscard]] warning to not be ignored on methods that return a class marked [[nodiscard]] that are defined in the class itself. See D32207.

llvm-svn: 300756
This commit is contained in:
Craig Topper 2017-04-19 21:02:45 +00:00
parent 5af4515788
commit 61e14d8dfe
1 changed files with 1 additions and 1 deletions

View File

@ -1166,7 +1166,7 @@ void CodeGenFunction::EmitCaseStmtRange(const CaseStmt &S) {
if (Rem)
Rem--;
SwitchInsn->addCase(Builder.getInt(LHS), CaseDest);
LHS++;
++LHS;
}
return;
}