summaryrefslogtreecommitdiff
path: root/src/set_flt.c
diff options
context:
space:
mode:
authorzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2021-02-01 09:11:38 +0000
committerzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2021-02-01 09:11:38 +0000
commitd15730493f51116689d21bf127e5dff4f2811c39 (patch)
treee793ff4daffcf72e9d1915dddf022b4c06f50ebc /src/set_flt.c
parent4587f0234612ebb1f5f0af753ae5bd44481b8d63 (diff)
downloadmpfr-d15730493f51116689d21bf127e5dff4f2811c39.tar.gz
make it clear that we don't propagate the sign bit in mpfr_get_d and mpfr_set_d
and similar functions for binary32, decimal64 and binary128 git-svn-id: https://scm.gforge.inria.fr/anonscm/svn/mpfr/trunk@14296 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'src/set_flt.c')
-rw-r--r--src/set_flt.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/set_flt.c b/src/set_flt.c
index 7a0a7d9b2..6f60b7e5f 100644
--- a/src/set_flt.c
+++ b/src/set_flt.c
@@ -26,9 +26,9 @@ int
mpfr_set_flt (mpfr_ptr r, float f, mpfr_rnd_t rnd_mode)
{
/* we convert f to double precision and use mpfr_set_d;
- NaN and infinities should be preserved, and all single precision
- numbers are exactly representable in the double format, thus the
- conversion is always exact */
+ NaN and infinities should be preserved (except the sign bit for NaN),
+ and all single precision numbers are exactly representable in the double
+ format, thus the conversion is always exact */
return mpfr_set_d (r, (double) f, rnd_mode);
}