Bug 103469

Summary: [search] method reference in binary reports top enclosing method instead of anonymous
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: CoreAssignee: Frederic Fusier <frederic_fusier>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1   
Target Milestone: 3.2 M6   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Markus Keller CLA 2005-07-12 06:49:27 EDT
I20050627-1435 (3.1)

Import org.eclipse.ui.workbench as binary plugin and search for references to
PartPane#showViewMenu(..).

One match is reported in PresentablePart#getMenu(), but the match is really in
the anonymous new IPartMenu(){...}#showMenu(..):

    public IPartMenu getMenu() {
        if (!part.hasViewMenu()) {
            return null;
        }

        if (viewMenu == null) {
            viewMenu = new IPartMenu() {
                public void showMenu(Point location) {
                    part.showViewMenu(location);
                }
            };
        }

        return viewMenu;
    }

Maybe connected to bug 86293.
Comment 1 Frederic Fusier CLA 2006-03-15 16:31:19 EST
Cannot reproduce using build I20060314-1200
Comment 2 Markus Keller CLA 2006-03-16 09:06:37 EST
Still does not work. More exact steps to reproduce in I20060315-1200:
- new workspace
- File > Import... > Plug-ins and Fragments
- make sure "Import As: Binary projects" is selected
- press Next
- choose org.eclipse.ui.workbench
- press Finish

- open type "PartPane"
- select name of method showViewMenu(..) (in editor or outline)
- press Ctrl+Shift+G or Ctrl+H, Enter

=> Was: enclosing element rendered in Search view is
PresentablePart
    getMenu()

=> Expected: should be (same as if project imported as source, not binary):
PresentablePart
    getMenu()
        new IPartMenu() {...}
            showMenu(Point)
Comment 3 Frederic Fusier CLA 2006-03-16 09:37:51 EST
You're right, I imported the project with source folders. I can reproduce after having imported as binary => so, it's a duplicate...

*** This bug has been marked as a duplicate of 86293 ***