This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: floatToRawIntBits, doubleToRawLongBits, + cleanups.


>>>>> "Bryce" == Bryce McKinlay <bryce@albatross.co.nz> writes:

Bryce> We were missing the Float.floatToRawIntBits and
Bryce> Double.doubleToRawLongBits methods; this patch adds
Bryce> them. Presumably these are supposed to be different to their
Bryce> non-raw counterparts somehow, but I can't figure out how. The
Bryce> JDK seems to return the same values for all the inputs I've
Bryce> tried, including NaN.

There are multiple NaN representations.  doubleToLongBits always
returns a fixed value for any NaN, but doubleToRawLongBits returns the
actual NaN value.  The 1.3 online docs support this.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]