Bug 244339

Summary: [1.6][compiler] Internal compiler error for one of the test case classes
Product: [Eclipse Project] JDT Reporter: Olga Krupina <olga>
Component: CoreAssignee: Olivier Thomann <Olivier_Thomann>
Status: VERIFIED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: Olivier_Thomann
Version: 3.5   
Target Milestone: 3.2.2   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
The source origin none

Description Olga Krupina CLA 2008-08-15 16:33:58 EDT
While building a project which I am getting an error on the class that is an instance of TestCase:

Internal compiler error java.lang.ArrayIndexOutOfBoundsException: 5 at 
 org.eclipse.jdt.internal.compiler.codegen.StackMapFrameCodeStream.getLocal
 (StackMapFrameCodeStream.java:771) at 
 org.eclipse.jdt.internal.compiler.codegen.StackMapFrameCodeStream.aload
 (StackMapFrameCodeStream.java:93) at 
 org.eclipse.jdt.internal.compiler.codegen.CodeStream.load(CodeStream.java:5238) at 
 org.eclipse.jdt.internal.compiler.codegen.CodeStream.load(CodeStream.java:5138) at 
 org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.generateSyntheticFieldInitializationsIfN
 ecessary(ConstructorDeclaration.java:226) at 
 org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.internalGenerateCode
 (ConstructorDeclaration.java:286) at 
 org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.generateCode
 (ConstructorDeclaration.java:179) at 
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:533) at 
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:567) at 
 org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression.generateCode
 (QualifiedAllocationExpression.java:145) at 
 org.eclipse.jdt.internal.compiler.ast.LocalDeclaration.generateCode(LocalDeclaration.java:109) at 
 org.eclipse.jdt.internal.compiler.ast.AbstractMethodDeclaration.generateCode
 (AbstractMethodDeclaration.java:229) at 
 org.eclipse.jdt.internal.compiler.ast.AbstractMethodDeclaration.generateCode
 (AbstractMethodDeclaration.java:176) at 
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:533) at 
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.generateCode(TypeDeclaration.java:584) at 
 org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.generateCode
 (CompilationUnitDeclaration.java:214) at org.eclipse.jdt.internal.compiler.Compiler.process
 (Compiler.java:600) at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:411) at 
 org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.compile(AbstractImageBuilder.java:300) 
 at org.eclipse.jdt.internal.core.builder.BatchImageBuilder.compile(BatchImageBuilder.java:213) at 
 org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.compile(AbstractImageBuilder.java:237) 
 at org.eclipse.jdt.internal.core.builder.BatchImageBuilder.build(BatchImageBuilder.java:59) at 
 org.eclipse.jdt.internal.core.builder.JavaBuilder.buildAll(JavaBuilder.java:249) at 
 org.eclipse.jdt.internal.core.builder.JavaBuilder.build(JavaBuilder.java:174) at 
 org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:603) at 
 org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at 
 org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:167) at 
 org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:201) at 
 org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:230) at 
 org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at 
 org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:233) at 
 org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:307) at 
 org.eclipse.core.internal.resources.Project.build(Project.java:88) at 
 org.eclipse.ui.actions.BuildAction.invokeOperation(BuildAction.java:192) at 
 org.eclipse.ui.actions.WorkspaceAction.execute(WorkspaceAction.java:134) at 
 org.eclipse.ui.actions.WorkspaceAction$2.runInWorkspace(WorkspaceAction.java:429) at 
 org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:38) at 
 org.eclipse.core.internal.jobs.Worker.run(Worker.java:58)
Comment 1 Olivier Thomann CLA 2008-08-15 16:55:32 EDT
Please provide steps to reproduce and build id?
Comment 2 Olga Krupina CLA 2008-08-15 16:59:48 EDT
Created attachment 110132 [details]
The source origin

Here is the the source of the file where the compiler error exists.
Comment 3 Olivier Thomann CLA 2008-08-15 17:02:59 EDT
build id ?
Comment 4 Olga Krupina CLA 2008-08-15 17:03:53 EDT
Version: 3.2.1
Build id: M20060921-0945
Comment 5 Olivier Thomann CLA 2008-08-15 17:07:08 EDT
The 3.2.1 build contains many problems in 1.6 code. Many bugs have been fixed in 3.4 or the latest build 3.4 maintenance build.
However I'll try to reproduce using latest code.
Comment 6 Olivier Thomann CLA 2008-08-19 15:02:40 EDT
Reproduced with 3.2.1.
Closing as a dup of bug 168665.

*** This bug has been marked as a duplicate of bug 168665 ***
Comment 7 Olivier Thomann CLA 2008-08-19 15:03:03 EDT
Verified.
Comment 8 Olivier Thomann CLA 2008-08-19 15:05:44 EDT
Verified using 3.2.2.
Please move to the 3.2.2 build if you want a fix for this issue.