From 6b3feb91b8c0d78e49c0b0bcb969879c980505be Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Sat, 26 Sep 2015 22:22:08 +0200 Subject: AstExpression::coerce is always called with bAssign = true Change-Id: I883b8319fde0bd3cc65efe64eb2faf53e2344cfc --- idlc/inc/idlc/astexpression.hxx | 2 +- idlc/source/astexpression.cxx | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/idlc/inc/idlc/astexpression.hxx b/idlc/inc/idlc/astexpression.hxx index 327cbe9803c9..32c8bc72e894 100644 --- a/idlc/inc/idlc/astexpression.hxx +++ b/idlc/inc/idlc/astexpression.hxx @@ -108,7 +108,7 @@ public: { m_exprValue = pEv; } // Evaluation and value coercion - AstExprValue* coerce(ExprType type, bool bAssign=true); + AstExprValue* coerce(ExprType type); // Evaluate then store value inside this AstExpression void evaluate(); diff --git a/idlc/source/astexpression.cxx b/idlc/source/astexpression.cxx index 785e2284ad5c..0fec297deee1 100644 --- a/idlc/source/astexpression.cxx +++ b/idlc/source/astexpression.cxx @@ -685,7 +685,7 @@ coerce_value(AstExprValue *ev, ExprType t) } } -AstExprValue* AstExpression::coerce(ExprType t, bool bAssign) +AstExprValue* AstExpression::coerce(ExprType t) { AstExprValue *copy; @@ -753,8 +753,7 @@ AstExprValue* AstExpression::coerce(ExprType t, bool bAssign) copy = nullptr; } - if (bAssign) - m_exprValue = copy; + m_exprValue = copy; return copy; } -- cgit