Community
Participate
Working Groups
Using 0717 (M2 build), the following test case leads to a VerifyError at runtime. public class Test { boolean value; public static void main(String[] args) { System.out.println(new Test().booleanValue()); } public boolean booleanValue() { return (boolean) value; } } The problem is a collision in the bits used on the cast expression. We are working on a fix.
Change milestone.
Fix is to change the bit for NeedRuntimeCheckMASK to bit16 instead of bit5. Regression test added.
This problem arised when building a 2.1.1 jdt.core with 3.0-20030717 build. This code pattern is legite, and actually present in jdt.core from 2.1.1 stream. Without this fix, the compiler is fairly corrupted, due to a bit collision.
Curiously, neither JCK1.3a, JCK1.4, Jacks or our test suites did catch this scenario.
Fixed and released in HEAD. Regression test added (ConformTests.test232).
Verified.