diff options
| author | Richard M. Stallman | 2003-07-22 15:22:50 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2003-07-22 15:22:50 +0000 |
| commit | 13a105af210280e47773abd7f985f1985ea2cda6 (patch) | |
| tree | cc07d20655c1bb0c3e7a67b55620326cf10eee4c /lispref | |
| parent | 9258d6043fdaa7de4a61a9228e5c32c46b2553db (diff) | |
| download | emacs-13a105af210280e47773abd7f985f1985ea2cda6.tar.gz emacs-13a105af210280e47773abd7f985f1985ea2cda6.zip | |
(Function Documentation): Explain how to
show calling convention explicitly in the doc string.
Diffstat (limited to 'lispref')
| -rw-r--r-- | lispref/functions.texi | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/lispref/functions.texi b/lispref/functions.texi index 9ffb6561b23..e6f50bf4168 100644 --- a/lispref/functions.texi +++ b/lispref/functions.texi | |||
| @@ -411,7 +411,7 @@ of one or two complete sentences that summarize the function's purpose. | |||
| 411 | but since these spaces come before the starting double-quote, they are not part of | 411 | but since these spaces come before the starting double-quote, they are not part of |
| 412 | the string. Some people make a practice of indenting any additional | 412 | the string. Some people make a practice of indenting any additional |
| 413 | lines of the string so that the text lines up in the program source. | 413 | lines of the string so that the text lines up in the program source. |
| 414 | @emph{This is a mistake.} The indentation of the following lines is | 414 | @emph{That is a mistake.} The indentation of the following lines is |
| 415 | inside the string; what looks nice in the source code will look ugly | 415 | inside the string; what looks nice in the source code will look ugly |
| 416 | when displayed by the help commands. | 416 | when displayed by the help commands. |
| 417 | 417 | ||
| @@ -423,6 +423,19 @@ practice, there is no confusion between the first form of the body and the | |||
| 423 | documentation string; if the only body form is a string then it serves both | 423 | documentation string; if the only body form is a string then it serves both |
| 424 | as the return value and as the documentation. | 424 | as the return value and as the documentation. |
| 425 | 425 | ||
| 426 | The last line of the documentation string can specify calling | ||
| 427 | conventions different from the actual function arguments. Write | ||
| 428 | text like this: | ||
| 429 | |||
| 430 | @example | ||
| 431 | (fn @var{arglist}) | ||
| 432 | @end example | ||
| 433 | |||
| 434 | @noindent | ||
| 435 | following a blank line, with no newline following it inside the | ||
| 436 | documentation string. This feature is particularly useful for | ||
| 437 | macro definitions. | ||
| 438 | |||
| 426 | @node Function Names | 439 | @node Function Names |
| 427 | @section Naming a Function | 440 | @section Naming a Function |
| 428 | @cindex function definition | 441 | @cindex function definition |