Skip to content

Trying to subclass eglot-lsp-server #1423

Answered by joaotavora
benbellick asked this question in Q&A
Discussion options

You must be logged in to vote

Any suggestions on what I am doing wrong here?

You have to brush up on your Lisp quoting rules (and I must play closer attention):

(setq-local eglot-server-programs
     '((c-mode c-ts-mode c++-mode c++-ts-mode objc-mode)
                                 . (eglot-lsp-server . ("clangd"))))

Is how it should be. This of course is the same as

(setq-local eglot-server-programs
     '((c-mode c-ts-mode c++-mode c++-ts-mode objc-mode)  eglot-lsp-server "clangd"))

But what you had was wrong (for Eglot's purposes) because ' means the same as applying the form quote. So this:

(setq-local eglot-server-programs
     '((c-mode c-ts-mode c++-mode c++-ts-mode objc-mode)
                            …

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@joaotavora
Comment options

Comment options

You must be logged in to vote
1 reply
@benbellick
Comment options

Answer selected by joaotavora
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants