Commit f43a5263 authored by Glenn Morris's avatar Glenn Morris

cl-mapc small fixes

* lisp/emacs-lisp/cl-extra.el (cl-mapc): Add autoload cookie.  Doc fix.

* doc/misc/cl.texi (Mapping over Sequences): Mention cl-mapc naming oddity.
parent 516e1a08
......@@ -5,6 +5,7 @@
(Setf Extensions): Partially restore note about cl-getf,
mainly moved to lispref/variables.texi.
(Property Lists): Fix cl-getf typos.
(Mapping over Sequences): Mention cl-mapc naming oddity.
2012-10-29 Glenn Morris <rgm@gnu.org>
......
......@@ -199,6 +199,8 @@ because they are replaced by other standard Emacs Lisp features.
Finally, in a very few cases the old @file{cl.el} versions do not
behave in exactly the same way as the @file{cl-lib.el} versions.
@xref{Obsolete Features}.
@c There is also cl-mapc, which was called cl-mapc even before cl-lib.el.
@c But not autoloaded, so maybe not much used?
Since the old @file{cl.el} does not use a clean namespace, Emacs has a
policy that packages distributed with Emacs must not load @code{cl} at
......@@ -3309,13 +3311,15 @@ that it passes in the list pointers themselves rather than the
@code{car}s of the advancing pointers.
@end defun
@c FIXME does not exist?
@defun cl-mapc function seq &rest more-seqs
This function is like @code{cl-mapcar}, except that the values returned
by @var{function} are ignored and thrown away rather than being
collected into a list. The return value of @code{cl-mapc} is @var{seq},
the first sequence. This function is more general than the Emacs
primitive @code{mapc}.
primitive @code{mapc}. (Note that this function is called
@code{cl-mapc} even in @file{cl.el}, rather than @code{map*} as you
might expect.)
@c http://debbugs.gnu.org/6575
@end defun
@defun cl-mapl function list &rest more-lists
......
2012-10-30 Glenn Morris <rgm@gnu.org>
* emacs-lisp/cl-extra.el (cl-mapc): Add autoload cookie. Doc fix.
* emacs-lisp/cl.el (letf): Doc fix. (Bug#12760)
2012-10-29 Chong Yidong <cyd@gnu.org>
......
......@@ -149,8 +149,9 @@ the elements themselves.
(setq cl-list (cdr cl-list)))
(nreverse cl-res))))
;;;###autoload
(defun cl-mapc (cl-func cl-seq &rest cl-rest)
"Like `mapcar', but does not accumulate values returned by the function.
"Like `cl-mapcar', but does not accumulate values returned by the function.
\n(fn FUNCTION SEQUENCE...)"
(if cl-rest
(progn (apply 'cl-map nil cl-func cl-seq cl-rest)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment