diff options
Diffstat (limited to 'doc/lispref/sequences.texi')
-rw-r--r-- | doc/lispref/sequences.texi | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/doc/lispref/sequences.texi b/doc/lispref/sequences.texi index c3f4cff3015..1f6f80521c0 100644 --- a/doc/lispref/sequences.texi +++ b/doc/lispref/sequences.texi @@ -446,8 +446,7 @@ useful example of @code{sort}. @cindex seq library @cindex sequences, generalized The @file{seq.el} library provides the following additional sequence -manipulation macros and functions, prefixed with @code{seq-}. To use -them, you must first load the @file{seq} library. +manipulation macros and functions, prefixed with @code{seq-}. All functions defined in this library are free of side-effects; i.e., they do not modify any sequence (list, vector, or string) that @@ -577,6 +576,20 @@ starting from the first one for which @var{predicate} returns @code{nil}. @end example @end defun +@defun seq-split sequence length + This function returns a list consisting of sub-sequences of +@var{sequence} of (at most) length @var{length}. (The final element +may be shorter than @var{length} if the length of @var{sequence} isn't +a multiple of @var{length}. + +@example +@group +(seq-split [0 1 2 3 4] 2) +@result{} ([0 1] [2 3] [4]) +@end group +@end example +@end defun + @defun seq-do function sequence This function applies @var{function} to each element of @var{sequence} in turn (presumably for side effects), and returns |