-
Bug
-
Resolution: Cannot Reproduce
-
P4
-
None
-
1.2.0
-
sparc
-
solaris_2.5
Name: mgC56079 Date: 06/30/98
According to JLS 20.11.12 Math.sqrt(Double.MIN_VALUE) should return Double.NaN.
It returns Double.NEGATIVE_INFINITY on Win32 with jdk1.2beta4.
Works correctly with jdk1.1.x/win32, jdk1.1.x/Solaris and jdk1.2beta4/Solaris.
==== Here is a test ====
public class Sqrt {
public static void main(String s[]) {
System.out.println(Math.sqrt(Double.NEGATIVE_INFINITY));
}
}
=== Sample run (Win32, jdk1.2beta4J), wrong ===
% java Sqrt
Infinity
=== Sample run(Solaris or jdk1.1.x), correct ===
% java Sqrt
NaN
======================================================================