emacs-devel
[Top][All Lists]
Advanced

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

Re: Making `eglot-server-programs' a custom variable?


From: Arash Esbati
Subject: Re: Making `eglot-server-programs' a custom variable?
Date: Wed, 09 Nov 2022 23:07:30 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50

Philip Kaludercic <philipk@posteo.net> writes:

> How would making `eglot-server-programs' help in that respect?

If it's meant to be extended by users, then one could use the custom
interface for it, not add-to-list then.

> If the `defvar' were just to be replaced by a `defcustom', the result
> would still just be a variable, that couldn't be `add-to-list'ed
> before it is loaded.

This will depend on the implementation.  Say the current content of
`eglot-server-programs' is in `eglot-server-programs-builtin' and
`eglot-server-programs' is a custom variable, and you have a function
like this in eglot.el:

(defun eglot-server-programs ()
  (append eglot-server-programs
          eglot-server-programs-builtin))

then a user can just setq the custom eglot-server-programs without being
worry about the rest.

Best, Arash



reply via email to

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