(f) constructor of strictfp class not strictfp
Brought to you by:
cabbey,
daveshields
Although contructors cannot be explicitly declared strictfp, JLS 8.8.3 says that "a constructor is FP-strict if and only if its class is FP-strict." Jikes does not follow this rule.
The following program prints 'true' when compiled with javac 1.4.2, 'false' when compiled with Jikes:
import java.lang.reflect.*;
public strictfp class StrictFP
{
public StrictFP()
{
}
public static void main(String[] args) throws Throwable
{
Constructor ctor = StrictFP.class.getConstructor(new Class[0]);
System.out.println(Modifier.isStrict(ctor.getModifiers()));
}
}
This was tested using Jikes 1.21 on both Windows and Linux.
default constructors too. fixed in CVS.