Community
Participate
Working Groups
Against I20050623-2000. Create a new plug-in project. Do _not_ allow Eclipse to generate a Plugin class, and do not use a template. Add the single dependency org.eclipse.ui.workbench to the new plug-in, and create this class: package foo; import org.eclipse.ui.PlatformUI; public class Foo { private void bar() { PlatformUI.getWorkbench(). } } Invoke code assist after the dot. Nothing at all is reported. However, completing the expression with "close();" does compile. The problem appears to be that by not depending on org.eclipse.core.runtime, the new plug-in can't see the superinterface IAdaptable of IWorkbench. But this doesn't appear to be a problem for the compiler.
*** Bug 234020 has been marked as a duplicate of this bug. ***
Created attachment 102371 [details] Proposed fix Some super classes of the completed receiver are not on the classpath so when completion proposals inference try to resolve super classes then a problem is detected. In proposals inference this.lookupEnvironment.unitBeingCompleted is null so an AbortCompilation is thrown when problem is detected and proposals inference is stopped. To avoid this exception this.lookupEnvironment.unitBeingCompleted must be set to the compilation unit which contains the completion node.
Created attachment 102375 [details] Modified jar for regression tests
Philippe, Frederic, Jerome, please approve/review for RC3
This bug is not a regression from 3.3 and we are late in 3.4 so even if the fix looks simple it's too risky to add it 3.4. We should fix this bug in 3.4.1.
Created attachment 106818 [details] Updated patch
Released for 3.5M1. Tests added CompletionTests#testCompletionUnresolvedSuperclass() CompletionTests#testCompletionUnresolvedSuperinteface() Tests updated CompletionTests#testCompletionUnresolvedFieldType() CompletionTests#testCompletionUnresolvedParameterType() CompletionTests#testCompletionUnresolvedReturnType()
Created attachment 106823 [details] Proposed fix for 3.4.1 this.lookupEnvironment.unitBeingCompleted is set to the completed compilation unit to avoid the AbortCompilation.
Philippe - This is not a regression but the fix is simple and it will improve a lot the user experience when the classpath is incomplete. We should fix it for 3.4.1.
+1 for 3.4.1
Released for 3.4.1.
Verified for 3.5M1 using I20080805-1307
Closing as FIXED to be closed as VERIFIED during 3.4.1 verification pass.
Reopen to close as RESOLVED/FIXED to be closed as VERIFIED during 3.4.1 verification pass.
Fixed.
Verified for 3.4.1 using build M20080827-2000.