summaryrefslogtreecommitdiff
path: root/elisp/geiser-autodoc.el
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@gnu.org>2010-07-28 01:08:25 +0200
committerJose Antonio Ortega Ruiz <jao@gnu.org>2010-07-28 01:08:25 +0200
commit32f9cb274bc9abc16449d2da50df537c82cc7775 (patch)
tree70bdaee986544bb0ea5978bc33cbed47957fc003 /elisp/geiser-autodoc.el
parent235543503d09a52a513054ed75ac2506b7ce87bf (diff)
downloadgeiser-guile-32f9cb274bc9abc16449d2da50df537c82cc7775.tar.gz
geiser-guile-32f9cb274bc9abc16449d2da50df537c82cc7775.tar.bz2
Displaying variable values in autodoc.
Diffstat (limited to 'elisp/geiser-autodoc.el')
-rw-r--r--elisp/geiser-autodoc.el7
1 files changed, 6 insertions, 1 deletions
diff --git a/elisp/geiser-autodoc.el b/elisp/geiser-autodoc.el
index 06a10e7..1af0ae2 100644
--- a/elisp/geiser-autodoc.el
+++ b/elisp/geiser-autodoc.el
@@ -131,11 +131,16 @@ when `geiser-autodoc-display-module-p' is on."
(defun geiser-autodoc--str* (full-signature)
(geiser-autodoc--str (list (car full-signature)) full-signature))
+(defsubst geiser-autodoc--value-str (proc module value)
+ (let ((name (geiser-autodoc--proc-name proc module)))
+ (if value (format "%s => %s" name value) name)))
+
(defun geiser-autodoc--str (desc signature)
(let ((proc (car desc))
(args (cdr (assoc 'args signature)))
(module (cdr (assoc 'module signature))))
- (if (not args) (geiser-autodoc--proc-name proc module)
+ (if (not args)
+ (geiser-autodoc--value-str proc module (cdr (assoc 'value signature)))
(save-current-buffer
(set-buffer (geiser-syntax--font-lock-buffer))
(erase-buffer)