diff options
| author | Craig Topper <craig.topper@gmail.com> | 2017-04-19 21:02:45 +0000 |
|---|---|---|
| committer | Craig Topper <craig.topper@gmail.com> | 2017-04-19 21:02:45 +0000 |
| commit | 61e14d8dfed9f071961fdd3f0b2e8524c9a39b73 (patch) | |
| tree | 60c75979513bcafd38c16c18d124466da3986101 /clang/lib | |
| parent | 5af4515788840c5eed5c94fcb6542cdef74e04b2 (diff) | |
| download | bcm5719-llvm-61e14d8dfed9f071961fdd3f0b2e8524c9a39b73.tar.gz bcm5719-llvm-61e14d8dfed9f071961fdd3f0b2e8524c9a39b73.zip | |
[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
Diffstat (limited to 'clang/lib')
| -rw-r--r-- | clang/lib/CodeGen/CGStmt.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGStmt.cpp b/clang/lib/CodeGen/CGStmt.cpp index 0ebfd99363c..683f366ebe4 100644 --- a/clang/lib/CodeGen/CGStmt.cpp +++ b/clang/lib/CodeGen/CGStmt.cpp @@ -1166,7 +1166,7 @@ void CodeGenFunction::EmitCaseStmtRange(const CaseStmt &S) { if (Rem) Rem--; SwitchInsn->addCase(Builder.getInt(LHS), CaseDest); - LHS++; + ++LHS; } return; } |

