[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/eglot 1356844 097/139: Fix odd bugs
From: |
João Távora |
Subject: |
[elpa] externals/eglot 1356844 097/139: Fix odd bugs |
Date: |
Mon, 14 May 2018 09:55:01 -0400 (EDT) |
branch: externals/eglot
commit 1356844979c82e7a1b62055314a6a4326fed1576
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>
Fix odd bugs
* eglot.el (eglot--process-receive, eglot--request): Set status to
actual error message.
(eglot--managed-mode): Manage imenu-create-index-function
correctly.
(eglot--mode-line-format): Print error status.
---
eglot.el | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/eglot.el b/eglot.el
index 9ce7e26..807df98 100644
--- a/eglot.el
+++ b/eglot.el
@@ -495,7 +495,7 @@ is a symbol saying if this is a client or server
originated."
(not method)
(gethash id (eglot--pending-continuations
proc)))))
(eglot--log-event proc message 'server)
- (when err (setf (eglot--status proc) '("error" t)))
+ (when err (setf (eglot--status proc) `(,err t)))
(cond (method
;; a server notification or a server request
(let* ((handler-sym (intern (concat "eglot--server-"
@@ -566,7 +566,7 @@ response."
(error-fn (or error-fn
(cl-function
(lambda (&key code message &allow-other-keys)
- (setf (eglot--status process) '("error" t))
+ (setf (eglot--status process) `(,message t))
(eglot--warn
"(request) Request id=%s errored with code=%s: %s"
id code message)))))
@@ -780,7 +780,7 @@ Meaning only return locally if successful, otherwise exit
non-locally."
(add-hook 'completion-at-point-functions #'eglot-completion-at-point nil t)
(add-function :before-until (local 'eldoc-documentation-function)
#'eglot-eldoc-function)
- (advice-add imenu-create-index-function :around #'eglot-imenu)
+ (add-function :around (local imenu-create-index-function) #'eglot-imenu)
(flymake-mode 1)
(eldoc-mode 1))
(t
@@ -795,7 +795,7 @@ Meaning only return locally if successful, otherwise exit
non-locally."
(remove-hook 'completion-at-point-functions #'eglot-completion-at-point t)
(remove-function (local 'eldoc-documentation-function)
#'eglot-eldoc-function)
- (advice-remove imenu-create-index-function #'eglot-imenu))))
+ (remove-function (local imenu-create-index-function) #'eglot-imenu))))
(define-minor-mode eglot-mode
"Minor mode for all buffers managed by EGLOT in some way." nil
@@ -870,9 +870,10 @@ Uses THING, FACE, DEFS and PREPEND."
(mouse-3 eglot-reconnect "reconnect to server")))
,@(when serious-p
`("/" ,(eglot--mode-line-props
- status 'compilation-mode-line-fail
+ "error" 'compilation-mode-line-fail
'((mouse-1 eglot-events-buffer "go to events buffer")
- (mouse-3 eglot-clear-status "clear this status")))))
+ (mouse-3 eglot-clear-status "clear this status"))
+ (format "An error occured: %s\n" status))))
,@(when (and doing (not done-p))
`("/" ,(eglot--mode-line-props
doing 'compilation-mode-line-run
@@ -881,7 +882,8 @@ Uses THING, FACE, DEFS and PREPEND."
`("/" ,(eglot--mode-line-props
(format "%d" pending) 'warning
'((mouse-1 eglot-events-buffer "go to events buffer")
- (mouse-3 eglot-clear-status "clear this
status"))))))))))
+ (mouse-3 eglot-clear-status "clear this status"))
+ (format "%d pending requests\n" pending)))))))))
(add-to-list 'mode-line-misc-info `(eglot-mode (" [" eglot--mode-line-format
"] ")))
- [elpa] externals/eglot 05c67ee 112/139: Adjust flymake integration, (continued)
- [elpa] externals/eglot 05c67ee 112/139: Adjust flymake integration, João Távora, 2018/05/14
- [elpa] externals/eglot 9ff97a6 079/139: Increase request timeout length to 10 seconds, João Távora, 2018/05/14
- [elpa] externals/eglot 571b08f 076/139: Fix the odd bug here and there, João Távora, 2018/05/14
- [elpa] externals/eglot a7ddce6 080/139: Support javascript's javascript-typescript-langserver, João Távora, 2018/05/14
- [elpa] externals/eglot d40f9ac 094/139: Half-decent imenu support via textDocument/documentSymbol, João Távora, 2018/05/14
- [elpa] externals/eglot bbc64b4 087/139: Clean up client capabilities, João Távora, 2018/05/14
- [elpa] externals/eglot 9882bf2 072/139: Cleanup mistake with TextDocumentItem and TextDocumentIdentifier, João Távora, 2018/05/14
- [elpa] externals/eglot 8160cd4 071/139: Handle dynamic registration in general (but nothing specific yet), João Távora, 2018/05/14
- [elpa] externals/eglot c4ffabc 083/139: Half-decent completion support, João Távora, 2018/05/14
- [elpa] externals/eglot d431d41 088/139: Fix bug in hover support, João Távora, 2018/05/14
- [elpa] externals/eglot 1356844 097/139: Fix odd bugs,
João Távora <=
- [elpa] externals/eglot 6e76b08 100/139: Support workspace/applyEdit, João Távora, 2018/05/14
- [elpa] externals/eglot 5ce9ab0 106/139: Call eglot-eldoc-function after completion finishes, João Távora, 2018/05/14
- [elpa] externals/eglot ecd334f 101/139: Update README, João Távora, 2018/05/14
- [elpa] externals/eglot 39e8b9e 081/139: Add (dummy) tests and Travis CI integration, João Távora, 2018/05/14
- [elpa] externals/eglot 23b79e0 111/139: Shorten summary line to appease package-lint.el, João Távora, 2018/05/14
- [elpa] externals/eglot 37b7329 098/139: Reasonable textDocument/documentHighlight support, João Távora, 2018/05/14
- [elpa] externals/eglot d1cdcf1 119/139: Friendlier M-x eglot, João Távora, 2018/05/14
- [elpa] externals/eglot 764347d 128/139: New command eglot-help-at-point and a README update, João Távora, 2018/05/14
- [elpa] externals/eglot 9bf3166 136/139: Don't define a menu if nothing to show there for now, João Távora, 2018/05/14
- [elpa] externals/eglot 54fc885 113/139: More RLS-specifics: update Flymake diags when indexing done, João Távora, 2018/05/14