emacs-devel
[Top][All Lists]
Advanced

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

Re: What's missing in ELisp that makes people want to use cl-lib?


From: Eli Zaretskii
Subject: Re: What's missing in ELisp that makes people want to use cl-lib?
Date: Sat, 28 Oct 2023 22:14:22 +0300

> Date: Sat, 28 Oct 2023 12:10:23 -0700
> Cc: emacs-devel@gnu.org
> From: Jim Porter <jporterbugs@gmail.com>
> 
> On 10/28/2023 8:39 AM, Stefan Kangas wrote:
> > Is it possible that certain abstractions or functions are filling a gap
> > in Emacs Lisp itself?  In the case of `cl-pushnew', I happen to think
> > that the answer is yes.
> 
> I agree with this. I can speak about Eshell in particular, since it's 
> historically used a bit of cl-lib, and I've added more usage to it.
> 
> By far the number one cl-lib thing Eshell uses is 'cl-assert'.

cl-assert is a macro in cl-macs, so it isn't relevant to this
discussion.

> After that, the next most important cl-lib thing (in my opinion) is 
> generic functions.

If you mean cl-defgeneric and cl-defmethod, they again are not in
cl-lib, so not relevant to this discussion.  Moreover, they are
defined in cl-generic.el, which is preloaded.

> Related to the above is 'cl-defstruct'.

cl-defstruct is again a macro in cl-macs, not in cl-lib.

> Finally, Eshell uses a few miscellaneous cl-lib functions, some of which 
> are probably necessary, and some of which are just conveniences. The 
> (probable) necessities are: cl-progv and cl-mapc. The conveniences are: 
> cl-loop, cl-flet, cl-list*, cl-remove-if, cl-incf, and cl-decf.

These are the only ones relevant to this discussion.



reply via email to

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