Bug 80223

Summary: [search] Declaration search doesn't consider visibility to determine overriding methods
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: CoreAssignee: Frederic Fusier <frederic_fusier>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1   
Target Milestone: 3.1 M5   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Markus Keller CLA 2004-12-05 15:13:46 EST
I20041130-0800

a/A.java:
package a;
public class A {
    void m() {}
}

b/B.java:
package b;
public class B extends a.A {
    void m() {}
}

The compiler emits a warning that method b.B#m() does *not* override a.A#m().
However, a search for declarations (and occurrences) of method a.A#m() also
reports b.B#m(), which is wrong.
Comment 1 Frederic Fusier CLA 2004-12-30 12:48:00 EST
Fixed.

Now only A.m() method declaration is found.

[jdt-core-internal]
Change done in MethodLocator.resolveLevel(Binding).
Test case added in JavaSearchBugsTests.
Comment 2 David Audel CLA 2005-02-14 11:33:02 EST
Verified for 3.1M5