From ea7a22aaa4020c0fc150dfef9e7cf7c32d5141b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89milie=20Feral?= Date: Mon, 9 Oct 2017 13:30:57 +0200 Subject: [PATCH] [poincare] Fix bug in power::simplify Change-Id: I29b843a87d2fd4d6327e43c2fda06e5d47573b28 --- poincare/src/power.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/poincare/src/power.cpp b/poincare/src/power.cpp index 6850feed9..f2e877fe8 100644 --- a/poincare/src/power.cpp +++ b/poincare/src/power.cpp @@ -151,7 +151,7 @@ void Power::immediateSimplify() { } // x^1 if (b->isOne()) { - replaceWith(new Rational(Integer(1), true)); + replaceWith(const_cast(operand(0)), true); return; } // p^q with p, q rationals