chickadee » ck-macros » c-map1

(c-map1 '(OP ...) L) → listsyntax

Yields a list by calling the quoted operation on each item in the given list. Analogous to map, but only accepts one list. (See also c-map2 ... c-map5 for versions that accept more lists.) Prior to version 0.2.0, this was named c-map.

(ck () (c-quote (c-map1 '(c-cons 'a) '(1 2))))
;; ==> '((a . 1) (a . 2))