]> git.eshelyaron.com Git - emacs.git/commit
Ensure completion terminates in correct buffer
authorAndrew Schwartzmeyer <andrew@schwartzmeyer.com>
Sun, 21 Jun 2020 04:47:04 +0000 (21:47 -0700)
committerJoão Távora <joaotavora@gmail.com>
Mon, 27 Jul 2020 09:11:44 +0000 (10:11 +0100)
commit836127f39447fb93ffc9f2af2d0b0abbc2b4f824
treefb6cd3d5afaa106d6bbc115a95f403273cb95dc3
parentad701795985377401eb007a2eeb5ece65d47b0dc
Ensure completion terminates in correct buffer

To design a completion-in-region-function replacement that leverages
the elements in completion-at-point-functions, we must ensure that
their :exit-function parts execute in the correct buffer.  That is the
buffer where the text to be completed lives, not necessarily the
buffer being used for user interaction.

Later on, this guarantee should be provided by Emacs itself, perhaps
by putting the correct with-current-buffer call in completion--done.

Copyright-paperwork-exempt: yes
Co-authored-by: João Távora <joaotavora@gmail.com>
* eglot.el (eglot-completion-at-point): Ensure :exit-function's
buffer is where the source is.

GitHub-reference: close https://github.com/joaotavora/eglot/issues/505
lisp/progmodes/eglot.el