[Cfp-interest 3175] The modf fubcton
Damian McGuckin
damianm at esi.com.au
Sat Aug 10 23:10:22 PDT 2024
7.12.7.18
The description does not mention that the integral value is that nearest
to x (in a rounded sense) as mandated in Annex F. That implies that the
fractional part lies in the range [-0.5, +0.5].
ASIDE - Note that the design of both it and frexp() predate IEEE 754.
F.10.4.18 The modf function
(the syntax needs to be swapped for consistency)
-2- modf(+/- INF, iptr) stores +/- INF in the object pointed to by iptr and
returns +/- 0
Paragraph 3 can be made simpler by using roundeven() and avoiding the
need to save and restore the rounding mode.
+/- should be the plus-or-minus symbol.
INF should be the infinity symbol.
Thanks - Damian
Pacific Engineering Systems International ..... 20D Grose St, Glebe NSW 2037
Ph:+61-2-8571-0847 .. Fx:+61-2-9692-9623 | unsolicited email not wanted here
Views & opinions here are mine and not those of any past or present employer
More information about the Cfp-interest
mailing list