aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2009-04-29 20:29:43 +0000
committerEli Friedman <eli.friedman@gmail.com>2009-04-29 20:29:43 +0000
commit267c0ab1b9a15768f3f15abbfc40ce344751c78b (patch)
treefc1dbc81fa452752a0a6f2cf6030abe2595e5cfc
parent2f87216d26d2fce02d2aa6d6dd0a37d61f75fdfb (diff)
Minor simplification; also silences gcc warning.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70406 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/AST/ExprConstant.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/AST/ExprConstant.cpp b/lib/AST/ExprConstant.cpp
index 45cf24b963..fce59133c1 100644
--- a/lib/AST/ExprConstant.cpp
+++ b/lib/AST/ExprConstant.cpp
@@ -927,7 +927,7 @@ bool IntExprEvaluator::VisitBinaryOperator(const BinaryOperator *E) {
bool Result;
if (E->getOpcode() == BinaryOperator::EQ) {
Result = LHSValue.getLValueOffset() == RHSValue.getLValueOffset();
- } else if (E->getOpcode() == BinaryOperator::NE) {
+ } else {
Result = LHSValue.getLValueOffset() != RHSValue.getLValueOffset();
}
return Success(Result, E);