diff options
author | Lars Ingebrigtsen <larsi@gnus.org> | 2020-12-27 09:00:23 +0100 |
---|---|---|
committer | Lars Ingebrigtsen <larsi@gnus.org> | 2020-12-27 09:00:23 +0100 |
commit | 0f790464d547dd57a857d88dab309b286067ac45 (patch) | |
tree | 9636601e10be40551a54a0c2d403f48ca39db4f3 /lisp/emacs-lisp/shortdoc.el | |
parent | 714ca849ba658405ddde698cdc5836c4c9b289ca (diff) | |
download | emacs-0f790464d547dd57a857d88dab309b286067ac45.tar.gz emacs-0f790464d547dd57a857d88dab309b286067ac45.tar.bz2 emacs-0f790464d547dd57a857d88dab309b286067ac45.zip |
Add new predicates for sequence lengths
* doc/lispref/sequences.texi (Sequence Functions): Document them.
* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Mark them as
side-effect-free.
* lisp/emacs-lisp/shortdoc.el (list): Mention them.
* src/fns.c (Flength): Mention them in the doc string.
(length_internal): New function.
(Flength_less, Flength_greater, Flength_equal): New defuns.
(syms_of_fns): Sym them.
Diffstat (limited to 'lisp/emacs-lisp/shortdoc.el')
-rw-r--r-- | lisp/emacs-lisp/shortdoc.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/emacs-lisp/shortdoc.el b/lisp/emacs-lisp/shortdoc.el index 9d183e0d4e9..c6259f89711 100644 --- a/lisp/emacs-lisp/shortdoc.el +++ b/lisp/emacs-lisp/shortdoc.el @@ -618,6 +618,12 @@ There can be any number of :example/:result elements." "Data About Lists" (length :eval (length '(a b c))) + (length< + :eval (lenth< '(a b c) 1)) + (length> + :eval (lenth> '(a b c) 1)) + (length= + :eval (lenth> '(a b c) 3)) (safe-length :eval (safe-length '(a b c)))) |