aboutsummaryrefslogtreecommitdiff
path: root/gcc/real.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/real.c')
-rw-r--r--gcc/real.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/real.c b/gcc/real.c
index 8c263e0..bfb8462 100644
--- a/gcc/real.c
+++ b/gcc/real.c
@@ -4930,11 +4930,13 @@ mpfr_from_real (mpfr_ptr m, const REAL_VALUE_TYPE *r)
{
/* We use a string as an intermediate type. */
char buf[128];
+ int ret;
real_to_hexadecimal (buf, r, sizeof (buf), 0, 1);
/* mpfr_set_str() parses hexadecimal floats from strings in the same
format that GCC will output them. Nothing extra is needed. */
- gcc_assert (mpfr_set_str (m, buf, 16, GMP_RNDN) == 0);
+ ret = mpfr_set_str (m, buf, 16, GMP_RNDN);
+ gcc_assert (ret == 0);
}
/* Convert from MPFR to REAL_VALUE_TYPE. */