[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#60974: 30.0.50; byte-compile-preprocess mutates self evaluating form
From: |
Vibhav Pant |
Subject: |
bug#60974: 30.0.50; byte-compile-preprocess mutates self evaluating forms in expanded macro bodies |
Date: |
Tue, 07 Feb 2023 18:32:46 +0530 |
User-agent: |
Evolution 3.46.3 |
On Thu, 2023-02-02 at 11:04 -0500, Stefan Monnier wrote:
> > Alternatively, we could define a macro, store its expanded form in
> > a
> > variable and run it through `cconv-closure-convert`, checking
> > afterwards whether the original value changed or not. It feels a
> > little
> > more reliable, but writing it might be a little tricky.
>
> I was thinking of doing something like:
>
> (let ((f '(lambda () (interactive ...) ...)))
> (should (equal f
> (let ((fc (copy-tree f)))
> (byte-compile fc)
> fc))))
>
>
> -- Stefan
>
I wrote a variant of this that specifically calls `cconv-closure-
convert`, and checks if the interactive spec has been modified, using
`eq`. It fails on master, and passes with the patch installed.
--
Vibhav Pant
vibhavp@gmail.com
GPG: 7ED1 D48C 513C A024 BE3A 785F E3FB 28CB 6AB5 9598
60974-tests.diff
Description: Text Data
signature.asc
Description: This is a digitally signed message part