]> git.eshelyaron.com Git - emacs.git/commit
Control strictness towards incoming lsp messages
authorJoão Távora <joaotavora@gmail.com>
Fri, 23 Nov 2018 12:31:15 +0000 (12:31 +0000)
committerJoão Távora <joaotavora@gmail.com>
Fri, 23 Nov 2018 12:31:37 +0000 (12:31 +0000)
commitd3fc3ce7e70df0a92931c31fcadb625d81b9f0bc
tree8f1d98ca0b64efd485858a18578229b4a102b04e
parent333009a5c5e02dd23d6c7204e8b04f15ffff020c
Control strictness towards incoming lsp messages

A new variable, eglot-strict-mode controls whether Eglot is strict or
lax with regard to incoming LSP messages.

1. Bug reports should be tested with eglot-strict-mode set to
   '(disallow-non-standard-keys enforce-required-keys)

2. Users struggling to get non-standard servers working set this
   variable to '(), nil.  For now, by popular demand, this is the
   default value.

Note that this commit in particular introduces a new infrastructure,
but does not yet alter any code in Eglot to use it.  Neither is the
variable eglot--lsp-interface-alist populated.

* eglot-tests.el (eglot-strict-interfaces): New test.

* eglot.el (eglot--lsp-interface-alist): New variable.
(eglot-strict-mode): New variable.
(eglot--call-with-interface): New helper.
(eglot--dbind): New macro.
(eglot--lambda): New macro.

GitHub-reference: per https://github.com/joaotavora/eglot/issues/144
GitHub-reference: per https://github.com/joaotavora/eglot/issues/156
lisp/progmodes/eglot.el