emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/elpa fc6879f 084/139: Explain why didOpen on after-reve


From: João Távora
Subject: [elpa] externals/elpa fc6879f 084/139: Explain why didOpen on after-revert-hook is a bad idea
Date: Mon, 14 May 2018 09:53:41 -0400 (EDT)

branch: externals/elpa
commit fc6879fc69dc0a2cfda6168ee65920efb4a770c1
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>

    Explain why didOpen on after-revert-hook is a bad idea
    
    The reason is that the global find-file-hook is called again, and that
    already does the didOpen. Too many didOpen's would be bad.
    
    * eglot.el (eglot--managed-mode): Remove commented lines.
---
 eglot.el | 2 --
 1 file changed, 2 deletions(-)

diff --git a/eglot.el b/eglot.el
index 2ab4781..068e2ca 100644
--- a/eglot.el
+++ b/eglot.el
@@ -784,7 +784,6 @@ Meaning only return locally if successful, otherwise exit 
non-locally."
     (add-hook 'flymake-diagnostic-functions 'eglot-flymake-backend nil t)
     (add-hook 'kill-buffer-hook 'eglot--signal-textDocument/didClose nil t)
     (add-hook 'before-revert-hook 'eglot--signal-textDocument/didClose nil t)
-    ;;(add-hook 'after-revert-hook 'eglot--signal-textDocument/didOpen nil t)
     (add-hook 'before-save-hook 'eglot--signal-textDocument/willSave nil t)
     (add-hook 'after-save-hook 'eglot--signal-textDocument/didSave nil t)
     (add-hook 'xref-backend-functions 'eglot-xref-backend nil t)
@@ -796,7 +795,6 @@ Meaning only return locally if successful, otherwise exit 
non-locally."
     (remove-hook 'before-change-functions 'eglot--before-change t)
     (remove-hook 'kill-buffer-hook 'eglot--signal-textDocument/didClose t)
     (remove-hook 'before-revert-hook 'eglot--signal-textDocument/didClose t)
-    ;; (remove-hook 'after-revert-hook 'eglot--signal-textDocument/didOpen t)
     (remove-hook 'before-save-hook 'eglot--signal-textDocument/willSave t)
     (remove-hook 'after-save-hook 'eglot--signal-textDocument/didSave t)
     (remove-hook 'xref-backend-functions 'eglot-xref-backend t)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]