summaryrefslogtreecommitdiff
path: root/elisp/geiser-doc.el
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2021-12-03 21:24:45 +0000
committerjao <jao@gnu.org>2021-12-03 21:24:45 +0000
commit045b61b8681222456b8df6d4d153907a6879eca9 (patch)
tree87d2c3486e67507e91f6a604aff8d73d432e5aed /elisp/geiser-doc.el
parent8c2fcf6b8a072f6fe896178747119766c6609dd0 (diff)
downloadgeiser-045b61b8681222456b8df6d4d153907a6879eca9.tar.gz
geiser-045b61b8681222456b8df6d4d153907a6879eca9.tar.bz2
Fix: more careful display of signatures
In some cases, Guile cannot figure out a signature and it comes back as #f (:t in emacs-land), rather than a list.
Diffstat (limited to 'elisp/geiser-doc.el')
-rw-r--r--elisp/geiser-doc.el16
1 files changed, 8 insertions, 8 deletions
diff --git a/elisp/geiser-doc.el b/elisp/geiser-doc.el
index 908ff3a..44a06ba 100644
--- a/elisp/geiser-doc.el
+++ b/elisp/geiser-doc.el
@@ -149,14 +149,14 @@ help (e.g. browse an HTML page) implementing this method.")
'help-echo help)))
(defun geiser-doc--insert-button (target module impl &optional sign)
- (let ((link (geiser-doc--make-link target module impl))
- (text (format "%s" (or (and sign
- (geiser-autodoc--str* sign))
- target
- module)))
- (help (format "%smodule %s"
- (if target (format "%s in " target) "")
- (or module "<unknown>"))))
+ (let* ((link (geiser-doc--make-link target module impl))
+ (sign (when sign (if (listp sign) sign (list target))))
+ (text (format "%s" (or (and sign (geiser-autodoc--str* sign))
+ target
+ module)))
+ (help (format "%smodule %s"
+ (if target (format "%s in " target) "")
+ (or module "<unknown>"))))
(insert-text-button text
:type 'geiser-doc--button
'face 'geiser-font-lock-doc-link