|
From: | Dmitry Gutov |
Subject: | Re: Adding support for xref jumping to headers/interfaces |
Date: | Fri, 24 Nov 2023 03:37:37 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 |
On 15/11/2023 23:32, Spencer Baugh wrote:
Dmitry Gutov <dmitry@gutov.dev> writes:On 11/11/2023 14:38, Spencer Baugh wrote:So e.g. c-ts-mode could define c-find-signature, which has a clear meaning for C.And c-mode will not.Some major modes will support things which other major modes do not support. Users will use the best one, whatever it is, and we'll change the default to whatever it is, eventually. I don't see an issue.
I don't see why we have to limit the users to specific major mode, when one might have functionality others don't have, and vice versa.
Like now, for example, many will likely stay with CC Mode for a while because of it more lax behavior in macro-heavy codebases, where c-ts-mode chokes and shows syntax errors.
While others will hopefully like c/c++-ts-mode with its more accurate and faster parsing and highlighting.
Anyway, I've pushed an update to the same branch (feature/xref-find-extra). Again, it's something to try out, not a done deal:
* The command is called xref-find-all-definitions, with appropriate behavior when invoked without prefix argument (appends the results from all kinds and shows them together, with duplicates removed).
* The Eglot implementation doesn't include 'references' in the list of kinds anymore, just because those are not definitions.
* New commands for the 3 popular kinds, bound to "M-' e", "M-' i" and "M-'t". The command which shows all moved to "M-' M-'".
What does everyone think?IMO the "all kinds together" view is interesting, but it all depends on what people actually find useful.
[Prev in Thread] | Current Thread | [Next in Thread] |