From: Eshel Yaron Date: Thu, 8 Aug 2024 11:20:49 +0000 (+0200) Subject: eglot.el: Cease overriding 'flymake-diagnostic-functions' X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=230f3423d027b8a7aa52194576fa42ffd900d0ad;p=emacs.git eglot.el: Cease overriding 'flymake-diagnostic-functions' --- diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 9c55402cc05..b57cfe260e1 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -2032,7 +2032,6 @@ Use `eglot-managed-p' to determine if current buffer is managed.") (add-hook 'post-self-insert-hook #'eglot--post-self-insert-hook nil t) (add-hook 'pre-command-hook #'eglot--pre-command-hook nil t) (eglot--setq-saving xref-prompt-for-identifier nil) - (eglot--setq-saving flymake-diagnostic-functions '(eglot-flymake-backend)) (eglot--setq-saving company-backends '(company-capf)) (eglot--setq-saving company-tooltip-align-annotations t) (eglot--setq-saving eldoc-documentation-strategy @@ -2041,6 +2040,7 @@ Use `eglot-managed-p' to determine if current buffer is managed.") (add-function :before-until (local 'imenu-create-index-function) #'eglot-imenu)) (unless (eglot--stay-out-of-p 'flymake) + (add-hook 'flymake-diagnostic-functions #'eglot-flymake-backend nil t) (if flymake-mode (flymake-start) (flymake-mode 1))) (unless (eglot--stay-out-of-p 'eldoc) (add-hook 'eldoc-documentation-functions #'eglot-hover-eldoc-function @@ -2065,6 +2065,7 @@ Use `eglot-managed-p' to determine if current buffer is managed.") (remove-hook 'pre-command-hook #'eglot--pre-command-hook t) (remove-hook 'eldoc-documentation-functions #'eglot-hover-eldoc-function t) (remove-hook 'eldoc-documentation-functions #'eglot-signature-eldoc-function t) + (remove-hook 'flymake-diagnostic-functions #'eglot-flymake-backend t) (cl-loop for (var . saved-binding) in eglot--saved-bindings do (set (make-local-variable var) saved-binding)) (remove-function (local 'imenu-create-index-function) #'eglot-imenu)