[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#2544: 23.0.60; Could etags please try find a local tag first?

From: Dmitry Gutov
Subject: bug#2544: 23.0.60; Could etags please try find a local tag first?
Date: Wed, 21 Jul 2021 01:36:08 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0

On 20.07.2021 19:56, Eli Zaretskii wrote:

Because when one uses more precise backends, "find definition" gets
fewer hits, and you don't really need to choose which ones to start with
-- the current file or otherwise.

When a backend returns just one hit, this is a non-issue.  The OP
specifically described a situation where there are many functions with
the same name in the project.  That's the use case we are discussing.

Static analysis can very often determine which of the multiple functions with the same name will be used at a particular call site. Yes, there are exceptions (which will happen less frequently than with etags), like when we're trying to jump to a virtual function with overloads in several subclasses. But jumping to such function call from a file with one of the definitions, and not being able to determine which of the functions is going to be called, is going to be an even more rare occurrence.

And even so, those backends can choose to sort the results starting with the current file by default. No user option needed.

I don't see how the backend can affect this situation.  Especially
since the etags backend is also quite accurate.

I'm saying etags' particular characteristics and varied usage patterns justify the addition of an etags-specific variable.

I don't see much use for it for other backends, but if I'm proven wrong, that proof would also provide some new information which would help generalize the feature. This can happen at a later stage.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]