Community
Participate
Working Groups
This bytecode leads to invalid stack map frames. Compile and run this test case in 1.6 mode: public class X { public static void main(String[] args) { } void foo(Object[] o) {} void bar(boolean b) { foo(new Object[] {"", "", b ? "" : ""}); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ } } When running it with java -XX:-FailOverToOldVerifier -Xverify:all..., I get: Exception in thread "main" java.lang.VerifyError: Bad type on operand stack in method X.bar(Z)V at offset 28 This is trivially fixed. Needs to be backported to 3.2.2
Created attachment 56443 [details] Proposed fix
Created attachment 56444 [details] Regression test
Released for 3.3M5. Philippe, Candidate for 3.2.2 ?
+1 for 3.2.2.
Released for 3.2.2. Added regression test org.eclipse.jdt.core.tests.compiler.regression.StackMapAttributeTest#test024 for 3.2.2 and org.eclipse.jdt.core.tests.compiler.regression.StackMapAttributeTest#test025 for 3.3M5
Verified for 3.2.2 using build M20070112-1200
Verified for 3.3 M5 using build I20070205-0009
*** Bug 183682 has been marked as a duplicate of this bug. ***
*** Bug 185210 has been marked as a duplicate of this bug. ***