]> git.eshelyaron.com Git - emacs.git/commit
Add lisp/backend-completion.el
authorJoão Távora <joaotavora@gmail.com>
Fri, 25 Nov 2022 13:03:45 +0000 (13:03 +0000)
committerJoão Távora <joaotavora@gmail.com>
Fri, 25 Nov 2022 13:03:45 +0000 (13:03 +0000)
commitc807121fbd360d968f24048298ef54b098ac7e2c
tree6b09f6627672462e4206cff310e94f41d84d0759
parentd34fc7b7aa9d2779ebbada5cecd8bd2806e3e01e
Add lisp/backend-completion.el

This completion style is meant to be used with a "programmable
completion" table that interfaces with an external providing
completions, such as a shell utility, an inferior process, an http
server.  The table and external tool are tasked to do the matching of
the pattern string to the potential candidates of completion, and as
such it fully controls the style.

When this completion style is in use, the usual styles configured
by the user or other in `completion-styles' are completely
overriden.  This can be seen as a drawback, but, on the other hand,
the regular the full data set to be available in Emacs' addressing
space, which is often not feasible.

* lisp/backend-completion.el: New file.

* lisp/progmodes/eglot.el (Package-Requires): Require
backend-completion.
(completion-styles-alist): Don't set it.
(eglot--lsp-backend-style-call)
(eglot--lsp-backend-style-try-completion)
(eglot--lsp-backend-style-all-completions): Delete.
lisp/backend-completion.el [new file with mode: 0644]
lisp/progmodes/eglot.el