Name: akC45999 Date: 01/13/97
The Java Virtual Machine, section frem, claims:
If either value is NaN, the resuly is NaN.
Meanwhile, following test fails:
--------------------- drem00101.java
package javasoft.sqe.tests.vm.frem.frem001.frem00101;
import java.io.PrintStream;
import java.lang.Float;
public class frem00101
{
public static void main(String argv[])
{
System.exit(run(argv, System.out));
}
public static int run(String argv[], PrintStream out)
{
float NaN = Float.NaN;
float f = 2.71f;
float zero = 0.0f;
if (! Float.isNaN(f % NaN))
return 2;
else if (! Float.isNaN(NaN % zero))
return 2;
else if (! Float.isNaN(NaN % NaN))
return 2;
return 0;
}
}
---------------------
======================================================================