]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix textdocument/hover responses where markedstring is a plist ()
authorMichal Krzywkowski <k.michal@zoho.com>
Fri, 17 Aug 2018 23:56:01 +0000 (01:56 +0200)
committerJoão Távora <joaotavora@gmail.com>
Fri, 17 Aug 2018 23:56:01 +0000 (00:56 +0100)
* eglot.el (eglot--hover-info): Forward all non-vector content to
eglot--format-markup.

GitHub-reference: https://github.com/joaotavora/eglot/issues/72

lisp/progmodes/eglot.el

index 13c72abdc4e463be5facfd76b335f2a1e1b8b757..6f3676117a7153e335dbdc8eb9104b0b58a47a8d 100644 (file)
@@ -1446,8 +1446,7 @@ is not active."
   (let ((heading (and range (pcase-let ((`(,beg . ,end) (eglot--range-region range)))
                               (concat (buffer-substring beg end)  ": "))))
         (body (mapconcat #'eglot--format-markup
-                         (append (cond ((vectorp contents) contents)
-                                       ((stringp contents) (list contents)))) "\n")))
+                         (if (vectorp contents) contents (list contents)) "\n")))
     (when (or heading (cl-plusp (length body))) (concat heading body))))
 
 (defun eglot--sig-info (sigs active-sig active-param)