Community
Participate
Working Groups
Search for fully qualified constructor name reports nothing Steps: - open type org.eclipse.jdt.ui.actions.CCPActionGroup - select CCPActionGroup(IViewPart) - Search > Search... -> search for references to constructor in workspace is fine - again, but change search string to "org.eclipse.jdt.ui.actions.CCPActionGroup" -> nothing found (expected: finds references to other constructors as well) - again, but change search string to "CCPActionGroup" -> fine: finds references to all constructors
Oops, the original bug description was inexact. When searching for references to methods, I can just omit the parenthesis and search finds references to all (overloaded) methods with that name. Doing the same when searching for constructors fails: searching for references to constructor "org.eclipse.jdt.ui.actions.CCPActionGroup.CCPActionGroup" (note the name of the constructor in addition to the name of the class) fails. However, searching for "org.eclipse.jdt.ui.actions.CCPActionGroup" (only class name) succeeds. Both forms (with and without constructor name) should find the same references.
We are not interpreting the search string. Moving to CORE.
Since the class simple name is always the same as the constructor name, you don't need to repeat it in the search string. In your case, searching for the constructor CCPActionGroup() you should use the "org.eclipse.jdt.ui.actions.CCPActionGroup()" search string as you noticed. We should document this.
Yes, I know I don't have to repeat the name. But I'd like to be able to repeat it and still find the results. IMO documenting this doesn't solve the problem, since no user's gonna read that doc. Search for references to all overloaded methods with a common name: - select method - Ctrl+H - delete parameters and parentheses - press Search This pattern should work for constructors as well.
We cannot support both. If you have the search string "a.b.c.d.d()", how do you know if it is the constructor d() in class d in package a.b.c, or if it is the constructor d() in class d in package a.b.c.d ?
Hmm, I see. You could consider both as matching, but that would probaly raise more problems than it solves. I can also live with an explaining doc.
Created attachment 11532 [details] Proposed patch
Patch released.
Verified that the doc is in place in 200406110010