add ability to search for callers, etc. of class template methods

RESOLVED FIXED

Status

RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: froydnj, Assigned: twointofive)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(firefox45 affected)

Details

(Reporter)

Description

3 years ago
Head to:

https://dxr.mozilla.org/mozilla-central/source/xpcom/glue/nsCOMArray.h#292

(the definition of the InsertObjectAt method, but any method in nsCOMArray<T> will do)

Try to search for callers, which gets you to this URL:

https://dxr.mozilla.org/mozilla-central/search?q=%2Bcallers%3A%22nsCOMArray%3A%3AInsertObjectAt%28T+*%2C+int32_t%29%22

which is not quite correct.

What I really want in this case is all instantiations of nsCOMArray<T>::InsertObjectAt(T*, int).  I suppose the same sort of logic would apply to template functions as well.
Another related issue is that when you want to search for, e.g., all other references to something like nsBaseHashtable::EnumerateRead based on a variable foo.EnumerateRead, the search for references link substitutes the values of template parameters.

Template specialization and partial specialization provide interesting corner cases, and I can see wanting to search for references/callers of templated methods that don't refer to the specialized method bodies. Arguably, it might make sense to overload override/overridden to get at specialization information.
(Assignee)

Comment 2

3 years ago
Fixed by https://github.com/mozilla/dxr/pull/540
Assignee: nobody → twointofive
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.