Mercurial > emacs
changeset 1889:1ed971f67bfd
(describe-function): Print the arglist if the function is bytecode or a list.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 19 Feb 1993 05:06:28 +0000 |
parents | 86ff3942d7e1 |
children | 0ca7640360bd |
files | lisp/help.el |
diffstat | 1 files changed, 18 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/help.el Fri Feb 19 04:14:25 1993 +0000 +++ b/lisp/help.el Fri Feb 19 05:06:28 1993 +0000 @@ -311,10 +311,24 @@ ;;; (nth 1 def) )) (t ""))) - (terpri)) - (if (documentation function) - (princ (documentation function)) - (princ "not documented")) + (terpri) + (if (documentation function) + (princ (documentation function)) + (princ "not documented")) + (cond ((byte-code-function-p def) + (save-excursion + (set-buffer standard-output) + (or (eq (char-after (1- (point-max))) ?\n) + (terpri))) + (terpri) + (princ (car (append def nil)))) + ((eq (car-safe def) 'lambda) + (save-excursion + (set-buffer standard-output) + (or (eq (char-after (1- (point-max))) ?\n) + (terpri))) + (terpri) + (princ (nth 1 def))))) (print-help-return-message) ;; Return the text we displayed. (save-excursion (set-buffer standard-output) (buffer-string))))