r373825 - Remove redundant !HasDependentValue check. NFCI.
Simon Pilgrim via cfe-commits
cfe-commits at lists.llvm.org
Sat Oct 5 06:20:51 PDT 2019
Author: rksimon
Date: Sat Oct 5 06:20:51 2019
New Revision: 373825
URL: http://llvm.org/viewvc/llvm-project?rev=373825&view=rev
Log:
Remove redundant !HasDependentValue check. NFCI.
Fixes cppcheck warning.
Modified:
cfe/trunk/lib/Sema/SemaStmt.cpp
Modified: cfe/trunk/lib/Sema/SemaStmt.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaStmt.cpp?rev=373825&r1=373824&r2=373825&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaStmt.cpp (original)
+++ cfe/trunk/lib/Sema/SemaStmt.cpp Sat Oct 5 06:20:51 2019
@@ -963,7 +963,7 @@ Sema::ActOnFinishSwitchStmt(SourceLocati
// condition is constant.
llvm::APSInt ConstantCondValue;
bool HasConstantCond = false;
- if (!HasDependentValue && !TheDefaultStmt) {
+ if (!TheDefaultStmt) {
Expr::EvalResult Result;
HasConstantCond = CondExpr->EvaluateAsInt(Result, Context,
Expr::SE_AllowSideEffects);
More information about the cfe-commits
mailing list