From b8993eafa95daa806ed6887447b493bc062856cc Mon Sep 17 00:00:00 2001 From: Ruben Dashyan Date: Tue, 10 Mar 2020 13:52:18 +0100 Subject: [PATCH] [poincare/expression] Call reduce instead of deepReduce --- poincare/src/expression.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/poincare/src/expression.cpp b/poincare/src/expression.cpp index f274ab3c6..62dc03bc0 100644 --- a/poincare/src/expression.cpp +++ b/poincare/src/expression.cpp @@ -604,7 +604,7 @@ void Expression::ParseAndSimplifyAndApproximate(const char * text, Expression * Expression Expression::simplify(ExpressionNode::ReductionContext reductionContext) { sSimplificationHasBeenInterrupted = false; - Expression e = deepReduce(reductionContext); + Expression e = reduce(reductionContext); if (!sSimplificationHasBeenInterrupted) { e = e.deepBeautify(reductionContext); } @@ -679,11 +679,11 @@ void Expression::simplifyAndApproximate(Expression * simplifiedExpression, Expre // Step 1: we reduce the expression ExpressionNode::ReductionContext userReductionContext = ExpressionNode::ReductionContext(context, complexFormat, angleUnit, ExpressionNode::ReductionTarget::User, symbolicComputation); const bool isUnitConvert = type() == ExpressionNode::Type::UnitConvert; - Expression e = clone().deepReduce(userReductionContext); + Expression e = clone().reduce(userReductionContext); if (sSimplificationHasBeenInterrupted) { sSimplificationHasBeenInterrupted = false; ExpressionNode::ReductionContext systemReductionContext = ExpressionNode::ReductionContext(context, complexFormat, angleUnit, ExpressionNode::ReductionTarget::SystemForApproximation, symbolicComputation); - e = deepReduce(systemReductionContext); + e = reduce(systemReductionContext); } *simplifiedExpression = Expression(); if (sSimplificationHasBeenInterrupted) {