]> granicus.if.org Git - clang/commitdiff
Minor simplification; also silences gcc warning.
authorEli Friedman <eli.friedman@gmail.com>
Wed, 29 Apr 2009 20:29:43 +0000 (20:29 +0000)
committerEli Friedman <eli.friedman@gmail.com>
Wed, 29 Apr 2009 20:29:43 +0000 (20:29 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70406 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/ExprConstant.cpp

index 45cf24b96389cc0fe8784c85d2892aca274315b7..fce59133c105371429cd1e8d6db7877ed3bea548 100644 (file)
@@ -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);