Bug 89562 - IAE in code assist on wildcard type
Summary: IAE in code assist on wildcard type
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Linux-GTK
: P3 normal (vote)
Target Milestone: 3.1 RC1   Edit
Assignee: David Audel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-30 10:21 EST by Tom Hofmann CLA
Modified: 2005-05-19 04:31 EDT (History)
0 users

See Also:


Attachments
Util.diff (566 bytes, patch)
2005-03-30 10:22 EST, Tom Hofmann CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Hofmann CLA 2005-03-30 10:21:16 EST
I20050329-2000-gtk

- invoke code complete at the caret (|) in this CU:

package m6testing;

import java.util.*;

public class StarGeneric {
	void foo(List<?> star) {
		star.|
	}
}

I get the exception below. This is because Util does not deal with multiply
nested types (see bug 85293).

!ENTRY org.eclipse.jdt.ui 4 0 2005-03-30 17:15:20.517
!MESSAGE Exception when processing proposal for: addAll()
!STACK 0
java.lang.IllegalArgumentException
	at org.eclipse.jdt.internal.core.util.Util.scanTypeBoundSignature(Util.java:2527)
	at
org.eclipse.jdt.internal.core.util.Util.scanTypeArgumentSignature(Util.java:2599)
	at
org.eclipse.jdt.internal.core.util.Util.scanTypeArgumentSignatures(Util.java:2566)
	at org.eclipse.jdt.internal.core.util.Util.scanClassTypeSignature(Util.java:2472)
	at org.eclipse.jdt.internal.core.util.Util.scanTypeSignature(Util.java:2297)
	at org.eclipse.jdt.core.Signature.getParameterCount(Signature.java:958)
	at
org.eclipse.jdt.internal.ui.text.java.ExperimentalResultCollector.createMethodReferenceProposal(ExperimentalResultCollector.java:55)
	at
org.eclipse.jdt.internal.ui.text.java.ExperimentalResultCollector.createJavaCompletionProposal(ExperimentalResultCollector.java:45)
	at
org.eclipse.jdt.ui.text.java.CompletionProposalCollector.accept(CompletionProposalCollector.java:161)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.findLocalMethods(CompletionEngine.java:2823)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.findIntefacesMethods(CompletionEngine.java:2549)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.findMethods(CompletionEngine.java:3263)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.findFieldsAndMethods(CompletionEngine.java:1939)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.complete(CompletionEngine.java:528)
	at
org.eclipse.jdt.internal.codeassist.CompletionEngine.complete(CompletionEngine.java:1167)
	at org.eclipse.jdt.internal.core.Openable.codeComplete(Openable.java:119)
	at
org.eclipse.jdt.internal.core.CompilationUnit.codeComplete(CompilationUnit.java:300)
	at
org.eclipse.jdt.internal.core.CompilationUnit.codeComplete(CompilationUnit.java:293)
	at
org.eclipse.jdt.internal.ui.text.java.JavaCompletionProcessor.internalComputeCompletionProposals(JavaCompletionProcessor.java:335)
	at
org.eclipse.jdt.internal.ui.text.java.JavaCompletionProcessor.computeCompletionProposals(JavaCompletionProcessor.java:313)
	at
org.eclipse.jface.text.contentassist.ContentAssistant.computeCompletionProposals(ContentAssistant.java:1470)
	at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.computeProposals(CompletionProposalPopup.java:250)
	at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.access$7(CompletionProposalPopup.java:247)
	at
org.eclipse.jface.text.contentassist.CompletionProposalPopup$1.run(CompletionProposalPopup.java:206)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69)
	at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.showProposals(CompletionProposalPopup.java:201)
	at
org.eclipse.jface.text.contentassist.ContentAssistant$2.run(ContentAssistant.java:319)
	at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:118)
	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2755)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2475)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1570)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1534)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:306)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:103)
	at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:228)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:338)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:151)
	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:585)
	at org.eclipse.core.launcher.Main.invokeFramework(Main.java:268)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:260)
	at org.eclipse.core.launcher.Main.run(Main.java:887)
	at org.eclipse.core.launcher.Main.main(Main.java:871)
Comment 1 Tom Hofmann CLA 2005-03-30 10:22:28 EST
Created attachment 19326 [details]
Util.diff

The attached patch fixes the symptom, but not the problem...
Comment 2 David Audel CLA 2005-05-19 04:31:35 EDT
The problem can not be reproduced in N20050517-0010

Closed.