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: Augusto Stoffel
Subject: Re: What's missing in ELisp that makes people want to use cl-lib?
Date: Wed, 15 Nov 2023 15:41:09 +0100
User-agent: Gnus/5.13 (Gnus v5.13)

On Sat, 11 Nov 2023 at 13:09, João Távora wrote:

> seq.el strength over cl-lib.el is that it is a generic sequence
> processing library.  IMO it _should_ be used if there is the suspicion
> that the sequences being in that data being processed by a given
> function can be custom seq.el sequences.  Or when there is good
> reason to suspect that one they might be such custom sequences.
>
> I think that seq.el _should_ be used in those situations because
> it expresses exactly this fact, so it becomes self-documenting.
>
> I think the argument that Gerd is making in his economic
> contributions is that very often seq.el is overkill.
>
> For example, in its current form should _not_ be used when
> there is certainty that the sequences are Lisp listsm because as I
> showed elsewhere here, seq-some is significantly slower than
> cl-some and cl-loop when processing lots of small lists.

FWIW, I don't really use seq for its polymorphism.  Rather, I just care
about miscellaneous operations such as seq-some, seq-filter, seq-uniq
where a list-only built-in is not available.

>From what I see in other people's code, this is by far the most frequent
reason to use seq- functions.



reply via email to

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