diff options
Diffstat (limited to 'src/doc.c')
| -rw-r--r-- | src/doc.c | 7 |
1 files changed, 5 insertions, 2 deletions
| @@ -36,6 +36,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 36 | 36 | ||
| 37 | Lisp_Object Qfunction_documentation; | 37 | Lisp_Object Qfunction_documentation; |
| 38 | 38 | ||
| 39 | extern Lisp_Object Qclosure; | ||
| 39 | /* Buffer used for reading from documentation file. */ | 40 | /* Buffer used for reading from documentation file. */ |
| 40 | static char *get_doc_string_buffer; | 41 | static char *get_doc_string_buffer; |
| 41 | static int get_doc_string_buffer_size; | 42 | static int get_doc_string_buffer_size; |
| @@ -374,6 +375,7 @@ string is passed through `substitute-command-keys'. */) | |||
| 374 | else if (EQ (funcar, Qkeymap)) | 375 | else if (EQ (funcar, Qkeymap)) |
| 375 | return build_string ("Prefix command (definition is a keymap associating keystrokes with commands)."); | 376 | return build_string ("Prefix command (definition is a keymap associating keystrokes with commands)."); |
| 376 | else if (EQ (funcar, Qlambda) | 377 | else if (EQ (funcar, Qlambda) |
| 378 | || (EQ (funcar, Qclosure) && (fun = XCDR (fun), 1)) | ||
| 377 | || EQ (funcar, Qautoload)) | 379 | || EQ (funcar, Qautoload)) |
| 378 | { | 380 | { |
| 379 | Lisp_Object tem1 = Fcdr (Fcdr (fun)); | 381 | Lisp_Object tem1 = Fcdr (Fcdr (fun)); |
| @@ -480,7 +482,7 @@ aren't strings. */) | |||
| 480 | } | 482 | } |
| 481 | else if (!STRINGP (tem)) | 483 | else if (!STRINGP (tem)) |
| 482 | /* Feval protects its argument. */ | 484 | /* Feval protects its argument. */ |
| 483 | tem = Feval (tem); | 485 | tem = Feval (tem, Qnil); |
| 484 | 486 | ||
| 485 | if (NILP (raw) && STRINGP (tem)) | 487 | if (NILP (raw) && STRINGP (tem)) |
| 486 | tem = Fsubstitute_command_keys (tem); | 488 | tem = Fsubstitute_command_keys (tem); |
| @@ -507,7 +509,8 @@ store_function_docstring (Lisp_Object fun, EMACS_INT offset) | |||
| 507 | Lisp_Object tem; | 509 | Lisp_Object tem; |
| 508 | 510 | ||
| 509 | tem = XCAR (fun); | 511 | tem = XCAR (fun); |
| 510 | if (EQ (tem, Qlambda) || EQ (tem, Qautoload)) | 512 | if (EQ (tem, Qlambda) || EQ (tem, Qautoload) |
| 513 | || (EQ (tem, Qclosure) && (fun = XCDR (fun), 1))) | ||
| 511 | { | 514 | { |
| 512 | tem = Fcdr (Fcdr (fun)); | 515 | tem = Fcdr (Fcdr (fun)); |
| 513 | if (CONSP (tem) && INTEGERP (XCAR (tem))) | 516 | if (CONSP (tem) && INTEGERP (XCAR (tem))) |