GNU bug report logs -
#72343
[PATCH] Fix eglot-server-programs for TeX modes
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
On Tue, Aug 6, 2024, 17:34 João Távora <joaotavora <at> gmail.com> wrote:
> * lisp/progmodes/eglot.el (eglot-server-programs): Explicitly list modes
> derived from tex-mode, so that the correct language id is guessed.
>
> Won't it break when another mode is derived from it?
>
Not really, since such a hypothetical mode has no support from the servers.
May I ask why
> don't you just use the :language-id cookie which is designed
> exactly for this -- to avoid a guess?
>
That doesn't work, because apparently Eglot picks the language id of the
first mode in the listing that applies, which previously was the generic
tex-mode. That doesn't allow distinguishing latex and plain TeX. Again, the
issue is not guessing the language id string from the mode name, but rather
choosing the right mode symbol to guess from.
(Above I say apparently because this is not documented behavior, although
it's easy to check or verify reading the code.)
[Message part 2 (text/html, inline)]
This bug report was last modified 361 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.