[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: pure-fns in byte-opt.el
From: |
Eli Zaretskii |
Subject: |
Re: pure-fns in byte-opt.el |
Date: |
Sat, 29 Jul 2017 20:21:12 +0300 |
> Date: Sat, 29 Jul 2017 12:34:46 -0400
> From: Mark Oteiza <address@hidden>
> Cc: address@hidden
>
> >So I think the problem happens in unidata-word-list-compress, and it
> >happens because make-vector, which that function calls always returns
> >the same vector, so the vectors used by that function and created by
> >it are all messed up.
>
> I don't follow: why does it always return the same vector?
That's how I understand what the byte compiler does when you declare
that function "pure".
> That
> particular call to make-vector should be unaffected by make-vector being
> marked pure, because its arguments aren't constants.
Sorry, I meant the make-vector call in unidata-gen-table-word-list,
whose result is passed to unidata-word-list-compress.
> OTOH, the form
> (make-vector 128 nil) would indeed get byte-compiled into the constant
> [nil nil … nil]
The problem, I think, is not with a single call, but with that call
being in a loop, and the code expects each iteration to produce a new
vector.
- Re: pure-fns in byte-opt.el, (continued)
- Re: pure-fns in byte-opt.el, Eli Zaretskii, 2017/07/27
- Re: pure-fns in byte-opt.el, Mark Oteiza, 2017/07/27
- Re: pure-fns in byte-opt.el, Eli Zaretskii, 2017/07/28
- Re: pure-fns in byte-opt.el, Mark Oteiza, 2017/07/28
- Re: pure-fns in byte-opt.el, Eli Zaretskii, 2017/07/29
- Re: pure-fns in byte-opt.el, Mark Oteiza, 2017/07/29
- Re: pure-fns in byte-opt.el,
Eli Zaretskii <=