diff options
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/lispref/lists.texi | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/lispref/lists.texi b/doc/lispref/lists.texi index 69f93009520..31cc3190854 100644 --- a/doc/lispref/lists.texi +++ b/doc/lispref/lists.texi | |||
| @@ -667,6 +667,18 @@ non-@code{nil}, it copies vectors too (and operates recursively on | |||
| 667 | their elements). | 667 | their elements). |
| 668 | @end defun | 668 | @end defun |
| 669 | 669 | ||
| 670 | @defun flatten-tree tree | ||
| 671 | Take @var{tree} and "flatten" it. | ||
| 672 | This always returns a list containing all the terminal nodes, or | ||
| 673 | leaves, of @var{tree}. Dotted pairs are flattened as well, and nil | ||
| 674 | elements are removed. | ||
| 675 | @end defun | ||
| 676 | |||
| 677 | @example | ||
| 678 | (flatten-tree '(1 (2 . 3) nil (4 5 (6)) 7)) | ||
| 679 | @result{}(1 2 3 4 5 6 7) | ||
| 680 | @end example | ||
| 681 | |||
| 670 | @defun number-sequence from &optional to separation | 682 | @defun number-sequence from &optional to separation |
| 671 | This returns a list of numbers starting with @var{from} and | 683 | This returns a list of numbers starting with @var{from} and |
| 672 | incrementing by @var{separation}, and ending at or just before | 684 | incrementing by @var{separation}, and ending at or just before |