Bug 47419 - ResolveTest.testLocalNameForClassFile fails
Summary: ResolveTest.testLocalNameForClassFile fails
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0 M6   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-25 09:09 EST by Olivier Thomann CLA
Modified: 2003-12-12 06:07 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Olivier Thomann CLA 2003-11-25 09:09:28 EST
Using latest from HEAD, running the ResolveTests leads to this stack trace:
java.lang.ClassCastException
	at
org.eclipse.jdt.internal.core.util.HandleFactory$1$Visitor.visit(HandleFactory.java:182)
	at
org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.traverse(ConstructorDeclaration.java:435)
	at
org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclaration.java:1022)
	at
org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.traverse(CompilationUnitDeclaration.java:305)
	at
org.eclipse.jdt.internal.core.util.HandleFactory.createElement(HandleFactory.java:292)
	at
org.eclipse.jdt.internal.core.SelectionRequestor.acceptLocalVariable(SelectionRequestor.java:191)
	at
org.eclipse.jdt.internal.codeassist.SelectionEngine.selectFrom(SelectionEngine.java:650)
	at
org.eclipse.jdt.internal.codeassist.SelectionEngine.select(SelectionEngine.java:520)
	at org.eclipse.jdt.internal.core.Openable.codeSelect(Openable.java:169)
	at org.eclipse.jdt.internal.core.ClassFile.codeSelect(ClassFile.java:134)
	at org.eclipse.jdt.internal.core.ClassFile.codeSelect(ClassFile.java:119)
	at
org.eclipse.jdt.core.tests.model.AbstractJavaModelTests.codeSelect(AbstractJavaModelTests.java:236)
	at
org.eclipse.jdt.core.tests.model.ResolveTests.testLocalNameForClassFile(ResolveTests.java:923)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:324)
	at junit.framework.TestCase.runTest(TestCase.java:154)
	at junit.framework.TestCase.runBare(TestCase.java:127)
	at junit.framework.TestResult$1.protect(TestResult.java:106)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.framework.TestResult.run(TestResult.java:109)
	at junit.framework.TestCase.run(TestCase.java:118)
	at junit.framework.TestSuite.runTest(TestSuite.java:208)
	at
org.eclipse.jdt.core.tests.model.SuiteOfTestCases$Suite.runTest(SuiteOfTestCases.java:98)
	at junit.framework.TestSuite.run(TestSuite.java:203)
	at
org.eclipse.jdt.core.tests.model.SuiteOfTestCases$Suite.superRun(SuiteOfTestCases.java:82)
	at
org.eclipse.jdt.core.tests.model.SuiteOfTestCases$1.protect(SuiteOfTestCases.java:70)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at
org.eclipse.jdt.core.tests.model.SuiteOfTestCases$Suite.run(SuiteOfTestCases.java:79)
	at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:395)
	at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:279)
	at
org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:30)
	at
org.eclipse.pde.internal.junit.runtime.CoreTestApplication.run(CoreTestApplication.java:26)
	at
org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:858)
	at org.eclipse.core.boot.BootLoader.run(BootLoader.java:461)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:324)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:299)
	at org.eclipse.core.launcher.Main.run(Main.java:767)
	at org.eclipse.core.launcher.Main.main(Main.java:601)

The test is excluded for now.
Comment 1 Darin Swanson CLA 2003-11-25 18:14:16 EST
On I20031121 I am getting the same stack trace dumped to the console (nothing 
in the log) during Java development.
Comment 2 Darin Swanson CLA 2003-11-25 18:14:56 EST
My trace:
java.lang.ClassCastException
        at org.eclipse.jdt.internal.core.util.HandleFactory$1$Visitor.visit(Hand
leFactory.java:249)
        at org.eclipse.jdt.internal.compiler.ast.MemberTypeDeclaration.traverse(
MemberTypeDeclaration.java:32)
        at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDe
claration.java:920)
        at org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.trav
erse(CompilationUnitDeclaration.java:305)
        at org.eclipse.jdt.internal.core.util.HandleFactory.createElement(Handle
Factory.java:296)
        at org.eclipse.jdt.internal.core.SelectionRequestor.acceptLocalVariable(
SelectionRequestor.java:191)
        at org.eclipse.jdt.internal.codeassist.SelectionEngine.selectFrom(Select
ionEngine.java:650)
        at org.eclipse.jdt.internal.codeassist.SelectionEngine.select(SelectionE
ngine.java:520)
        at org.eclipse.jdt.internal.core.Openable.codeSelect(Openable.java:169)
        at org.eclipse.jdt.internal.core.ClassFile.codeSelect(ClassFile.java:134
)
        at org.eclipse.jdt.internal.core.ClassFile.codeSelect(ClassFile.java:119
)
        at org.eclipse.jdt.internal.ui.text.java.hover.AbstractJavaEditorTextHov
er.getHoverInfo(AbstractJavaEditorTextHover.java:95)
        at org.eclipse.jdt.internal.ui.text.java.hover.BestMatchHover.getHoverIn
fo(BestMatchHover.java:140)
        at org.eclipse.jdt.internal.ui.text.java.hover.JavaEditorTextHoverProxy.
getHoverInfo(JavaEditorTextHoverProxy.java:69)
        at org.eclipse.jface.text.TextViewerHoverManager$2.run(TextViewerHoverMa
nager.java:119)
Comment 3 Jerome Lanneluc CLA 2003-12-12 06:07:00 EST
Was fixed in I20031211. Closing.