emacs-devel
[Top][All Lists]
Advanced

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

Re: Adding support for xref jumping to headers/interfaces


From: Spencer Baugh
Subject: Re: Adding support for xref jumping to headers/interfaces
Date: Tue, 16 May 2023 17:10:40 -0400

An option I didn't mention originally: Perhaps xref-find-definitions
could just show both implementation and interface.  That would remove
the need for any new keybindings.  The UI might be worse but perhaps
it could be improved.

This is inspired by this comment:
https://github.com/joaotavora/eglot/issues/302#issuecomment-534202561

The relevant excerpt:
> By the way, on a tangent, I think it's a mistake on LSP's part to
> import C++/Java's ecosystem of possible symbol loci. In Common Lisp,
> there are many different types of construct associated with a symbol
> and they are all "definitions". A good IDE like SLIME will use
> something akin to xref-find-definitions (indeed xref is modelled after
> SLIME) and categorize them properly in the result buffer if there is
> more than one. So the command should have been textDocument/definition
> with some kind of subtype parameter, or at least this is where xref
> should evolve to, i.e. xref should keep the single command
> xref-find-definitions and maybe augment it with some "definition-type"
> parameter.



reply via email to

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