emacs-devel
[Top][All Lists]
Advanced

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

Re: Bad moves with xref-find-definitions


From: Vitalie Spinu
Subject: Re: Bad moves with xref-find-definitions
Date: Sun, 26 Apr 2015 18:01:54 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

 >>> Dmitry Gutov on Sun, 26 Apr 2015 18:20:13 +0300 wrote:

 > On 04/26/2015 02:31 PM, Vitalie Spinu wrote:
 >> What do you currently do if there are multiple matching definitions of
 >> the "thing-at-point"? Prompt?

 > Show them all in the xref buffer. But if the backend is smart enough, it will
 > include the disambiguating context information as text properties on the
 > "thing-at-point" string.

Aha! I see. Would be nice to be able to flush those into some familiar
interface - IDO, HELM or at least grep-like buffers (compilation
buffers) so that one can use M-g n, M-g p without visiting the buffer.


 >> As to prompting, if you try to accommodate multiple backends, then
 >> merging completion candidates from multiple backends is a simple task
 >> when you prompt.

 > Not if you want to avoid duplicates. ...

 > So you can simply call `delete-dups' on ...
          ^^^ cannot?  

What's the exact problem except abandoning lazynes? Naively I think
about it like this. Gather all candidates. Delete-dups. Then take
backends in turn and see which one contain the reference. If unique, use
that backend, else use *xref* buffer.

I personally never had problems with too many candidates, so "being
lazy" is completely useless feature to me. I am also not convinced you
are gaining much speed here. Each backend has to operate with its own
list of candidates anyways.

  Vitalie



reply via email to

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