diff options
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/tool/interpr5.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/tool/interpr5.cxx b/sc/source/core/tool/interpr5.cxx index 6cc80b33e91a..2c357dbb99cf 100644 --- a/sc/source/core/tool/interpr5.cxx +++ b/sc/source/core/tool/interpr5.cxx @@ -1657,7 +1657,7 @@ void ScInterpreter::ScPow() if (fVal1 < 0 && fVal2 != 0.0) { int i = (int) (1 / fVal2 + ((fVal2 < 0) ? -0.5 : 0.5)); - if (rtl::math::approxEqual(1 / ((double) i), fVal2) && i % 2 != 0) + if (i % 2 != 0 && rtl::math::approxEqual(1 / ((double) i), fVal2)) PushDouble(-pow(-fVal1, fVal2)); else PushDouble(pow(fVal1, fVal2)); |