Community
Participate
Working Groups
Build ID: I20080617-2000 Steps To Reproduce: Unfortunately, I don't think there was anything specific that provoked this. I'm hoping the stack trace will be enough. The error was shown in the 'problems' tab in the 'errors' section. More information: Internal compiler error java.lang.IllegalArgumentException: info cannot be null at org.eclipse.jdt.internal.compiler.codegen.StackMapFrame.addStackItem(StackMapFrame.java:81) at org.eclipse.jdt.internal.compiler.ClassFile.traverse(ClassFile.java:7545) at org.eclipse.jdt.internal.compiler.ClassFile.completeCodeAttribute(ClassFile.java:1613) at org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.internalGenerateCode(ConstructorDeclaration.java:336) at org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.generateCode(ConstructorDeclaration.java:192) at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:530) at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:581) at org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.generateCode(CompilationUnitDeclaration.java:356) at org.eclipse.jdt.internal.compiler.Compiler.process(Compiler.java:755) at org.eclipse.jdt.internal.compiler.ProcessTaskManager.run(ProcessTaskManager.java:137) at java.lang.Thread.run(Unknown Source)
It seems that this is triggered by setting the compiler for the project to 1.6. Using 1.5 generates a few compiler errors about a method being labelled @override, but the class file extending an interface (ie: it's doing what it's supposed to), but when changed to 1.6, the compiler crashes with the listed exception trace. Cleaning the project and/or refreshing the project do not make any difference.
I'm able to reproduce this problem using the following class: package com.test; public class Test { public Test() {} public Test(String s) {} { for (int i : new int[] {1}) {}; } } If you create the following class, it will fail to compile using eclipse ganymede (3.4 build I20080617-2000) The error produced is: Internal compiler error java.lang.IllegalArgumentException: info cannot be null at org.eclipse.jdt.internal.compiler.codegen.StackMapFrame.addStackItem(StackMapFrame.java:81) at org.eclipse.jdt.internal.compiler.ClassFile.traverse(ClassFile.java:7498) at org.eclipse.jdt.internal.compiler.ClassFile.completeCodeAttribute(ClassFile.java:1613) at org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.internalGenerateCode(ConstructorDeclaration.java:336) at org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.generateCode(ConstructorDeclaration.java:192) at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:530) at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:581) at org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.generateCode(CompilationUnitDeclaration.java:356) at org.eclipse.jdt.internal.compiler.Compiler.process(Compiler.java:755) at org.eclipse.jdt.internal.compiler.ProcessTaskManager.run(ProcessTaskManager.java:137) at java.lang.Thread.run(Unknown Source)
dup of bug 238923 *** This bug has been marked as a duplicate of bug 238923 ***
Verified for 3.5M1 using I20080805-1307
Reproduced using test case from comment 2 in a 1.6 project. Verified for 3.4.1 using M20080827-2000.