mapcar-like FunctionsThe following functions are analogous to mapc/mapcar/mapcan and
mapl/maplist/mapcon (part of Common Lisp), but for alists,
plists and vectors.
Also, with slightly different semantics, the ‘mapt*’ family of functions for mapping over integers.
In the following table, the Common Lisp (CL) functions upon which the new Loopless (LL) functions are based are included for completeness and comparison.
| PKG | Result accumulation method | nil | list | nconc
|
|---|---|---|---|---|
| Values mapped over
| ||||
| cl | elements of a list | mapc | mapcar | mapcan
|
| cl | conses of a list | mapl | maplist | mapcon
|
| ll | (key . value)s of an alist | mapal | mapalist | mapacon
|
| ll | (key value)s of an alist | mapal* | mapalist* | mapacon*
|
| ll | (key value)s of a plist | mappl | mapplist | mappcon
|
| ll | elements of a vector | mapv | mapvector | mapvcon
|
| ll | integers from 0 below max | mapt | maptimes | maptcon
|
| ll | As above, but no iter var | mapt* | maptimes* | maptcon*
|
Note that the names of the new functions are constructed in a
consistent way, based on mapl/maplist/mapcon. The behavior is
more similar to mapc/mapcar/mapcan, however.