Community
Participate
Working Groups
1) create class X (Y type does not exist) public class X { void foo(){ Y var = new <cursor> } } 2) do ctrl+space at cursor location an NPE occur stacktrace: java.lang.NullPointerException at java.lang.String.<init>(String.java:165) at org.eclipse.jdt.internal.ui.text.java.ResultCollector.acceptClass (ResultCollector.java:81) at org.eclipse.jdt.internal.core.CompletionRequestorWrapper.acceptClass (CompletionRequestorWrapper.java:68) at org.eclipse.jdt.internal.codeassist.CompletionEngine.findTypesAndPackages (CompletionEngine.java:2315) at org.eclipse.jdt.internal.codeassist.CompletionEngine.complete (CompletionEngine.java:402) at org.eclipse.jdt.internal.codeassist.CompletionEngine.complete (CompletionEngine.java:842) at org.eclipse.jdt.internal.core.Openable.codeComplete (Openable.java:124) at org.eclipse.jdt.internal.core.CompilationUnit.codeComplete (CompilationUnit.java:101) at org.eclipse.jdt.internal.ui.text.java.JavaCompletionProcessor.internalComputeCom pletionProposals(JavaCompletionProcessor.java:342) at org.eclipse.jdt.internal.ui.text.java.JavaCompletionProcessor.computeCompletionP roposals(JavaCompletionProcessor.java:300) at org.eclipse.jface.text.contentassist.ContentAssistant.computeCompletionProposals (ContentAssistant.java:1279) at org.eclipse.jface.text.contentassist.CompletionProposalPopup.computeProposals (CompletionProposalPopup.java:177) at org.eclipse.jface.text.contentassist.CompletionProposalPopup.access$7 (CompletionProposalPopup.java:176) at org.eclipse.jface.text.contentassist.CompletionProposalPopup$3.run (CompletionProposalPopup.java:138) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:65) at org.eclipse.jface.text.contentassist.CompletionProposalPopup.showProposals (CompletionProposalPopup.java:133) at org.eclipse.jface.text.contentassist.ContentAssistant.showPossibleCompletions (ContentAssistant.java:1199) at org.eclipse.jdt.internal.ui.javaeditor.CompilationUnitEditor$AdaptedSourceViewer .doOperation(CompilationUnitEditor.java:234) at org.eclipse.ui.texteditor.ContentAssistAction$1.run (ContentAssistAction.java:84) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:65) at org.eclipse.ui.texteditor.ContentAssistAction.run (ContentAssistAction.java:82) at org.eclipse.jface.action.Action.runWithEvent(Action.java:769) at org.eclipse.ui.internal.WWinKeyBindingService.invoke (WWinKeyBindingService.java:134) at org.eclipse.ui.internal.WWinKeyBindingService.pressed (WWinKeyBindingService.java:109) at org.eclipse.ui.internal.WWinKeyBindingService$5.widgetSelected (WWinKeyBindingService.java:336) at org.eclipse.ui.internal.AcceleratorMenu$2.handleEvent (AcceleratorMenu.java:53) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:77) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:825) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:1692) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:1410) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1419) at org.eclipse.ui.internal.Workbench.run(Workbench.java:1402) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:831) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:432) at EclipseRuntimeLauncher.main(EclipseRuntimeLauncher.java:24)
'expectedTypes' must be valid types. Fixed.
Verified.