summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2011-06-24 00:25:52 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2011-06-24 14:44:08 +0200
commit0d0cdc731ce1b50467d901cae756d52a95f6220f (patch)
treed5273533abdace997d41960f46ee28f1efd807ac
parent204cd4abb1205f8de43b272f3b65d785c3f374c6 (diff)
downloadmxs-utils-0d0cdc731ce1b50467d901cae756d52a95f6220f.tar.gz
mxs-utils-0d0cdc731ce1b50467d901cae756d52a95f6220f.tar.xz
skip unnecessary tests
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--elftosb2/ElftosbAST.cpp14
1 files changed, 1 insertions, 13 deletions
diff --git a/elftosb2/ElftosbAST.cpp b/elftosb2/ElftosbAST.cpp
index 1eaf5eb..c2e1cf5 100644
--- a/elftosb2/ElftosbAST.cpp
+++ b/elftosb2/ElftosbAST.cpp
@@ -697,19 +697,7 @@ ExprASTNode * BinaryOpExprASTNode::reduce(EvalContext & context)
{
throw semantic_error(format_string("right hand side of %s operator failed to evaluate to an integer", getOperatorName().c_str()));
}
- rightValue = rightIntConst->getValue();
-
- // Perform the boolean operation.
- switch (m_op)
- {
- case kBooleanAnd:
- result = leftValue && rightValue;
- break;
-
- case kBooleanOr:
- result = leftValue && rightValue;
- break;
- }
+ result = rightIntConst->getValue();
}
else if (m_op == kBooleanAnd)
{