RE: Generating Modulo and Remainder Operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi David,

> So, you're saying modf() will work for signed and unsigned, floating and integer types?

The modf() Standard C Library routine works with double types.  Assuming your platform's double is a 64-bit float (of the ISO 60559 sort, which was derived from IEEE 754), that will handle integer types up to 53-bits of precision, of either positive or negative sign.

If you are working with 64-bit integers, then modf() will not be suitable.

If you are working with 32-bit integers, then modf() will be suitable.

Sincerely,
--Eljay



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux