Re:Converting binary floating-point numbers to integers
by CyberRabbi on Saturday October 23, 2021 @03:37PM
(#28971541)
I already mentioned the alternative. memcpy() into a char array.
[ Parent
| on HN ]
Re:Converting binary floating-point numbers to integers
by Cloudef on Sunday October 24, 2021 @06:05AM
(#28976433)
Memcpy doesnt fix endianess
Re:Converting binary floating-point numbers to integers
by CyberRabbi on Saturday November 06, 2021 @08:25PM
(#29135207)
It was never claimed to deal with endianness and while we're on the subject of binary-layout, union-based binary manipulation is even worse on that front as no specific binary layout is mandated for structures or floating points.