1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-01 20:30:28 +02:00

fixed repl command ,describe to also handle syntax

This commit is contained in:
Daniel Krueger 2012-03-28 18:25:15 +02:00 committed by Andy Wingo
parent 5e33d0aa37
commit e1fb0e811b

View file

@ -342,7 +342,12 @@ Find bindings/modules/packages."
(define-meta-command (describe repl (form)) (define-meta-command (describe repl (form))
"describe OBJ "describe OBJ
Show description/documentation." Show description/documentation."
(display (object-documentation (repl-eval repl (repl-parse repl form)))) (display
(object-documentation
(let ((input (repl-parse repl form)))
(if (symbol? input)
(module-ref (current-module) input)
(repl-eval repl input)))))
(newline)) (newline))
(define-meta-command (option repl . args) (define-meta-command (option repl . args)