Summary: | NPE during content assist | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Pratik Shah <ppshah> |
Component: | Core | Assignee: | Kent Johnson <kent_johnson> |
Status: | VERIFIED FIXED | QA Contact: | |
Severity: | major | ||
Priority: | P3 | CC: | daniel_megert, frederic_fusier, gmendel, kagrama, Olivier_Thomann, philippe_mulet |
Version: | 3.1 | ||
Target Milestone: | 3.1 RC3 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: |
Description
Pratik Shah
2005-06-13 16:00:34 EDT
What build are you using? Any steps to reproduce? I can produce this bug consistently in this one class. Other classes are working fine. Reopening the editor or cleaning the project didn't help. I can provide a screenshot of the class hierarchy if needed. 3.1RC2. Don't know what steps you can take to reproduce, unless you want to try loading a few GEF projects in your workspace. I was hoping the stack trace would give you enough information. Please provide steps to reproduce using GEF projects? We need to extract a regression test to track it down. I have verified that this problem occurs with this class on another computer as well. Check out org.eclipse.draw2d, org.eclipse.gef and org.eclipse.gef.examples.logic from dev.eclipse.org:/home/tools. The problem is in class LogicDiagramEditPart in the examples project. Reproduced. Content assist or search is broken. I'll try to isolate a small test case. Thanks for your help. I am also seeing this problem when trying to see who's calling a certain method in class ConnectionLayer. Select class and hit Ctrl+Alt+H. This problem does not happen in LogicDiagramEditPart, and that problem does not happen here. The NPE is at the same place though. Here's the stack trace. java.lang.NullPointerException at org.eclipse.jdt.internal.compiler.lookup.ClassScope.checkForInheritedMemberType s(ClassScope.java:652) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy (ClassScope.java:924) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectMemberTypes (ClassScope.java:709) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy (ClassScope.java:922) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.connectTypeHierar chy(CompilationUnitScope.java:254) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.completeTypeBindings (LookupEnvironment.java:249) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:354) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:378) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType (LookupEnvironment.java:131) at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage (PackageBinding.java:178) at org.eclipse.jdt.internal.compiler.lookup.Scope.getTypeOrPackage (Scope.java:2386) at org.eclipse.jdt.internal.compiler.lookup.Scope.getType (Scope.java:2131) at org.eclipse.jdt.internal.compiler.ast.SingleTypeReference.getTypeBinding (SingleTypeReference.java:39) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveType (TypeReference.java:141) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveSuperType (TypeReference.java:104) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.findSupertype (ClassScope.java:1074) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectSuperInterfaces (ClassScope.java:823) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy (ClassScope.java:914) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.connectTypeHierar chy(CompilationUnitScope.java:254) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.completeTypeBindings (LookupEnvironment.java:249) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:354) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:378) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType (LookupEnvironment.java:131) at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage (PackageBinding.java:178) at org.eclipse.jdt.internal.compiler.lookup.Scope.getTypeOrPackage (Scope.java:2386) at org.eclipse.jdt.internal.compiler.lookup.Scope.getType (Scope.java:2131) at org.eclipse.jdt.internal.compiler.ast.SingleTypeReference.getTypeBinding (SingleTypeReference.java:39) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveType (TypeReference.java:141) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveSuperType (TypeReference.java:104) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.findSupertype (ClassScope.java:1074) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectSuperclass (ClassScope.java:741) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy (ClassScope.java:913) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.connectTypeHierar chy(CompilationUnitScope.java:254) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.completeTypeBindings (LookupEnvironment.java:249) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:354) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:378) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType (LookupEnvironment.java:131) at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage (PackageBinding.java:178) at org.eclipse.jdt.internal.compiler.lookup.Scope.getTypeOrPackage (Scope.java:2386) at org.eclipse.jdt.internal.compiler.lookup.Scope.getType (Scope.java:2131) at org.eclipse.jdt.internal.compiler.ast.SingleTypeReference.getTypeBinding (SingleTypeReference.java:39) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveType (TypeReference.java:141) at org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveSuperType (TypeReference.java:104) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.findSupertype (ClassScope.java:1074) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectSuperclass (ClassScope.java:741) at org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy (ClassScope.java:913) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.connectTypeHierar chy(CompilationUnitScope.java:254) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.completeTypeBindings (LookupEnvironment.java:249) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:354) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.accept (MatchLocator.java:378) at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType (LookupEnvironment.java:131) at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage (PackageBinding.java:178) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.findImport (CompilationUnitScope.java:403) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.findSingleImport (CompilationUnitScope.java:456) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.faultInImports (CompilationUnitScope.java:321) at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.faultInTypes (CompilationUnitScope.java:390) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.process (MatchLocator.java:1442) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches (MatchLocator.java:939) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches (MatchLocator.java:980) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches (MatchLocator.java:1082) at org.eclipse.jdt.internal.core.search.JavaSearchParticipant.locateMatches (JavaSearchParticipant.java:94) at org.eclipse.jdt.internal.core.search.BasicSearchEngine.findMatches (BasicSearchEngine.java:208) at org.eclipse.jdt.internal.core.search.BasicSearchEngine.search (BasicSearchEngine.java:421) at org.eclipse.jdt.core.search.SearchEngine.search (SearchEngine.java:532) at org.eclipse.jdt.internal.corext.callhierarchy.CallerMethodWrapper.findChildren (CallerMethodWrapper.java:75) at org.eclipse.jdt.internal.corext.callhierarchy.MethodWrapper.performSearch (MethodWrapper.java:253) at org.eclipse.jdt.internal.corext.callhierarchy.MethodWrapper.doFindChildren (MethodWrapper.java:194) at org.eclipse.jdt.internal.corext.callhierarchy.MethodWrapper.getCalls (MethodWrapper.java:76) at org.eclipse.jdt.internal.ui.callhierarchy.DeferredMethodWrapper.getCalls (DeferredMethodWrapper.java:62) at org.eclipse.jdt.internal.ui.callhierarchy.DeferredMethodWrapper.fetchDeferredCh ildren(DeferredMethodWrapper.java:80) at org.eclipse.ui.progress.DeferredTreeContentManager$1.run (DeferredTreeContentManager.java:192) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76) Philippe : candidate for RC3 Testcase in 2 files: abstract class A<- implements I {} interface I { class M extends A {} } Perform code assist after the A Have a fix, need to check that the hierarchy is connected when source types are added late (code assist case). +1 for RC3 Dani: can you pls vote for it as well ? Symptoms are exception in codeassist. +1 for 3.1 RC3. *** Bug 99964 has been marked as a duplicate of this bug. *** Added CompletionTests testBug99811 *** Bug 100234 has been marked as a duplicate of this bug. *** *** Bug 100286 has been marked as a duplicate of this bug. *** Verified using N20050616-0010 + JDT/Core HEAD |