Mercurial > emacs
comparison lisp/apropos.el @ 49231:1cc18f262eab
(apropos): Restore autoload cookie. Fix error
message typo.
author | John Paul Wallington <jpw@pobox.com> |
---|---|
date | Tue, 14 Jan 2003 20:47:21 +0000 |
parents | bcb627207749 |
children | 37645a051842 |
comparison
equal
deleted
inserted
replaced
49230:6f94f884d68e | 49231:1cc18f262eab |
---|---|
438 (let ((doc (documentation-property symbol property raw))) | 438 (let ((doc (documentation-property symbol property raw))) |
439 (if doc (substring doc 0 (string-match "\n" doc)) | 439 (if doc (substring doc 0 (string-match "\n" doc)) |
440 "(not documented)")) | 440 "(not documented)")) |
441 (error "(error retrieving documentation)"))) | 441 (error "(error retrieving documentation)"))) |
442 | 442 |
443 | |
444 ;;;###autoload | |
443 (defun apropos (apropos-regexp &optional do-all) | 445 (defun apropos (apropos-regexp &optional do-all) |
444 "Show all bound symbols whose names match APROPOS-REGEXP. | 446 "Show all bound symbols whose names match APROPOS-REGEXP. |
445 With optional prefix DO-ALL or if `apropos-do-all' is non-nil, also | 447 With optional prefix DO-ALL or if `apropos-do-all' is non-nil, also |
446 show unbound symbols and key bindings, which is a little more | 448 show unbound symbols and key bindings, which is a little more |
447 time-consuming. Returns list of symbols and documentation found." | 449 time-consuming. Returns list of symbols and documentation found." |
471 (if (setq doc (condition-case nil | 473 (if (setq doc (condition-case nil |
472 (documentation symbol t) | 474 (documentation symbol t) |
473 (void-function | 475 (void-function |
474 "(alias for undefined function)") | 476 "(alias for undefined function)") |
475 (error | 477 (error |
476 "(error retrieving function documentation"))) | 478 "(error retrieving function documentation)"))) |
477 (substring doc 0 (string-match "\n" doc)) | 479 (substring doc 0 (string-match "\n" doc)) |
478 "(not documented)")) | 480 "(not documented)")) |
479 (when (boundp symbol) | 481 (when (boundp symbol) |
480 (apropos-documentation-property | 482 (apropos-documentation-property |
481 symbol 'variable-documentation t)) | 483 symbol 'variable-documentation t)) |