Exact conversion from native double to mpf_t

Marc Glisse marc.glisse at inria.fr
Sat Nov 25 20:56:46 CET 2023


On Sat, 25 Nov 2023, Andrea Monaco wrote:

> Does mpf_set_d perform an exact conversion from native double to mpf_t,
> with no rounding?

Looks like it, from a quick glance at the code.

> If my conjectures are correct, I think updating the manual would be
> nice.

True. Note that we recommend using MPFR instead of mpf_t for new code, 
though.

-- 
Marc Glisse


More information about the gmp-discuss mailing list