diff options
| author | Alan Mackenzie | 2015-12-07 10:39:07 +0000 |
|---|---|---|
| committer | Alan Mackenzie | 2015-12-07 10:39:07 +0000 |
| commit | f5c403d269f4f5079dc47853f16a51e9542ea238 (patch) | |
| tree | fc2cd75cc227517ff727579d70ca1b35097b9361 | |
| parent | 72c20d0be811966afccdb7551d3341d10d3be9a9 (diff) | |
| download | emacs-f5c403d269f4f5079dc47853f16a51e9542ea238.tar.gz emacs-f5c403d269f4f5079dc47853f16a51e9542ea238.zip | |
Amend doc of `mapconcat': it can take sequences, not merely strings.
* doc/lispref/functions.texi (Mapping Functions): Amend the doc of `mapconcat'
to say that SEPARATOR and the results from FUNCTION may be any character
sequences, not just strings. Add an @xref to "Sequences Arrays Vectors".
| -rw-r--r-- | doc/lispref/functions.texi | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/doc/lispref/functions.texi b/doc/lispref/functions.texi index 8835667b82d..7cc041fa77e 100644 --- a/doc/lispref/functions.texi +++ b/doc/lispref/functions.texi | |||
| @@ -861,15 +861,18 @@ into a list. @code{mapc} always returns @var{sequence}. | |||
| 861 | 861 | ||
| 862 | @defun mapconcat function sequence separator | 862 | @defun mapconcat function sequence separator |
| 863 | @code{mapconcat} applies @var{function} to each element of | 863 | @code{mapconcat} applies @var{function} to each element of |
| 864 | @var{sequence}: the results, which must be strings, are concatenated. | 864 | @var{sequence}; the results, which must be sequences of characters |
| 865 | Between each pair of result strings, @code{mapconcat} inserts the string | 865 | (strings, vectors, or lists), are concatenated into a single string |
| 866 | @var{separator}. Usually @var{separator} contains a space or comma or | 866 | return value. Between each pair of result sequences, @code{mapconcat} |
| 867 | other suitable punctuation. | 867 | inserts the characters from @var{separator}, which also must be a |
| 868 | string, or a vector or list of characters. @xref{Sequences Arrays | ||
| 869 | Vectors}. | ||
| 868 | 870 | ||
| 869 | The argument @var{function} must be a function that can take one | 871 | The argument @var{function} must be a function that can take one |
| 870 | argument and return a string. The argument @var{sequence} can be any | 872 | argument and returns a sequence of characters: a string, a vector, or |
| 871 | kind of sequence except a char-table; that is, a list, a vector, a | 873 | a list. The argument @var{sequence} can be any kind of sequence |
| 872 | bool-vector, or a string. | 874 | except a char-table; that is, a list, a vector, a bool-vector, or a |
| 875 | string. | ||
| 873 | 876 | ||
| 874 | @example | 877 | @example |
| 875 | @group | 878 | @group |