diff options
| author | Richard M. Stallman | 1993-02-19 05:06:28 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1993-02-19 05:06:28 +0000 |
| commit | 4591cb9059790dfb3fd0f322e9edfc82d2c73d24 (patch) | |
| tree | 61d5dd4b3024dc5dcbdf120f3eb1255a0c30b5c1 | |
| parent | 9b2471dfa9867cd987fe11e86c39b31bfcf72934 (diff) | |
| download | emacs-4591cb9059790dfb3fd0f322e9edfc82d2c73d24.tar.gz emacs-4591cb9059790dfb3fd0f322e9edfc82d2c73d24.zip | |
(describe-function): Print the arglist if the function is bytecode or a list.
| -rw-r--r-- | lisp/help.el | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/lisp/help.el b/lisp/help.el index d968aedb7a7..95d08297361 100644 --- a/lisp/help.el +++ b/lisp/help.el | |||
| @@ -311,10 +311,24 @@ C-w print information on absence of warranty for GNU Emacs." | |||
| 311 | ;;; (nth 1 def) | 311 | ;;; (nth 1 def) |
| 312 | )) | 312 | )) |
| 313 | (t ""))) | 313 | (t ""))) |
| 314 | (terpri)) | 314 | (terpri) |
| 315 | (if (documentation function) | 315 | (if (documentation function) |
| 316 | (princ (documentation function)) | 316 | (princ (documentation function)) |
| 317 | (princ "not documented")) | 317 | (princ "not documented")) |
| 318 | (cond ((byte-code-function-p def) | ||
| 319 | (save-excursion | ||
| 320 | (set-buffer standard-output) | ||
| 321 | (or (eq (char-after (1- (point-max))) ?\n) | ||
| 322 | (terpri))) | ||
| 323 | (terpri) | ||
| 324 | (princ (car (append def nil)))) | ||
| 325 | ((eq (car-safe def) 'lambda) | ||
| 326 | (save-excursion | ||
| 327 | (set-buffer standard-output) | ||
| 328 | (or (eq (char-after (1- (point-max))) ?\n) | ||
| 329 | (terpri))) | ||
| 330 | (terpri) | ||
| 331 | (princ (nth 1 def))))) | ||
| 318 | (print-help-return-message) | 332 | (print-help-return-message) |
| 319 | ;; Return the text we displayed. | 333 | ;; Return the text we displayed. |
| 320 | (save-excursion (set-buffer standard-output) (buffer-string)))) | 334 | (save-excursion (set-buffer standard-output) (buffer-string)))) |