Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 178688

Summary: Overloaded methods that take param with same short name confuses "Open method"
Product: [Eclipse Project] JDT Reporter: Zorzella Mising name <zorzella>
Component: CoreAssignee: David Audel <david_audel>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: Olivier_Thomann
Version: 3.3   
Target Milestone: ---   
Hardware: PC   
OS: All   
Whiteboard: stalebug

Description Zorzella Mising name CLA 2007-03-21 19:11:53 EDT
Build ID: I20070222-0951

Steps To Reproduce:
1. Create class "A" as on the fragment below. Note that it defines two classes with name "X", and two overloaded methods named "foo", each taking one of these two classes.

2. Put the cursor on bar's invocation of "foo". If you have "Toggle Mark Occurrence", you can note that it knows the first overloaded "foo" is the one being called

3 .But if you hit F3 (or CTRL-click it), you will get an "Open" dialog asking you which of the overloaded methods to follow.

the same happens if two "X" classes are defined in two different packages

-----------------------------------

public class A {
  public static class X {}

  public static class B {
    public static class X {}
  }
  
  void foo(B.X x) {}
  
  void foo(X x) {}
  
  void bar() {
    B.X x = null;
    foo(x);
  }
}


More information:
Comment 1 Martin Aeschlimann CLA 2007-03-22 11:43:16 EDT
I agree, code resolve should be able to evaluate the correct declaration
Comment 2 Olivier Thomann CLA 2009-06-25 15:22:07 EDT
David, please investigate if this still occurs.
Comment 3 David Audel CLA 2009-06-29 06:18:02 EDT
The problem still occurs
Comment 4 Eclipse Genie CLA 2018-09-22 16:08:13 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 5 Zorzella Mising name CLA 2019-01-22 12:54:49 EST
The problem still exists.