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: João Távora
Subject: Re: What's missing in ELisp that makes people want to use cl-lib?
Date: Thu, 16 Nov 2023 16:24:48 +0000

On Thu, Nov 16, 2023 at 4:02 PM Michael Heerdegen
<michael_heerdegen@web.de> wrote:
>
> João Távora <joaotavora@gmail.com> writes:

> >
> >   (("destructuring" (cl-destructuring-bind "FASTEST" 0.010157632 0 0.0)
> >     (pcase-let "1.3x SLOWER" 0.013152518000000002 0 0.0)
> >     (seq-let "14.8x (rel 11.4x) SLOWER" 0.15057331499999999
> >       6 0.04785139399999849))
>
> Isn't seq-let directly translated into a pcase-let call (it's a
> simplistic macro)?  How is this possible?

Yes, but look closely at the expansion ;-)

And you can also think.  How can that pcase-let call know at at
runtime whether it's dealing with a bare list, a vector/string,
or a custom sequence.  Only through runtime indirection
obviously!  Based on what?  Generic functions no less, seq-elt
in this case, which become slower when added to.

João



reply via email to

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