diff options
Diffstat (limited to 'Build/source/libs/mpfr/mpfr-src/src/pow_ui.c')
-rw-r--r-- | Build/source/libs/mpfr/mpfr-src/src/pow_ui.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c b/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c index 33aadf24723..456d6d18e74 100644 --- a/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c +++ b/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c @@ -1,7 +1,7 @@ /* mpfr_pow_ui-- compute the power of a floating-point by a machine integer -Copyright 1999-2019 Free Software Foundation, Inc. +Copyright 1999-2020 Free Software Foundation, Inc. Contributed by the AriC and Caramba projects, INRIA. This file is part of the GNU MPFR Library. @@ -108,13 +108,13 @@ mpfr_pow_ui (mpfr_ptr y, mpfr_srcptr x, unsigned long int n, mpfr_rnd_t rnd) err = prec - 1 - (mpfr_prec_t) i; /* First step: compute square from x */ MPFR_BLOCK (flags, - inexact = mpfr_mul (res, x, x, MPFR_RNDU); + inexact = mpfr_sqr (res, x, MPFR_RNDU); MPFR_ASSERTD (i >= 2); if (n & (1UL << (i-2))) inexact |= mpfr_mul (res, res, x, rnd1); for (i -= 3; i >= 0 && !MPFR_BLOCK_EXCEP; i--) { - inexact |= mpfr_mul (res, res, res, MPFR_RNDU); + inexact |= mpfr_sqr (res, res, MPFR_RNDU); if (n & (1UL << i)) inexact |= mpfr_mul (res, res, x, rnd1); }); |