bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#19454: 24.3; apply doesn't work as in Common Lisp


From: Stefan Monnier
Subject: bug#19454: 24.3; apply doesn't work as in Common Lisp
Date: Sat, 27 Dec 2014 20:14:55 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

tags 19454 notabug
thanks

> (apply 'mapcar 'list '((1 2))) ; ((1) (2))
> (apply 'mapcar 'list '((1 2) (3 4))) ; error

> The error is:

> *** Eval error ***  Wrong number of arguments: mapcar, 3

Nothing to do with `apply'.  You get the same error with

   (mapcar #'list '(1 2) '(3 4))

That's because Elisp is not Common-Lisp.  If you want Common Lisp's
mapcar, then use `cl-mapcar' (after requiring `cl-lib').


        Stefan





reply via email to

[Prev in Thread] Current Thread [Next in Thread]