GNU bug report logs - #65017
29.1; Byte compiler interaction with cl-lib function objects, removes symbol-function

Previous Next

Package: emacs;

Reported by: Eric Marsden <eric.marsden <at> risk-engineering.org>

Date: Wed, 2 Aug 2023 13:34:02 UTC

Severity: normal

Found in version 29.1

Done: Alan Mackenzie <acm <at> muc.de>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: Alan Mackenzie <acm <at> muc.de>, mattias.engdegard <at> gmail.com, 65017 <at> debbugs.gnu.org, eric.marsden <at> risk-engineering.org
Subject: bug#65017: 29.1; Byte compiler interaction with cl-lib function objects, removes symbol-function
Date: Sat, 05 Aug 2023 18:58:00 -0400
>> internal-macroexpand-for-load isn't being called in the context of a
>> byte compilation.  It might create a symbol with position which wrongly
>> matches, or fails to match, another symbol.  This is what has happened
>> in this bug.
>
> If internal-macroexpand-for-load is "verboten" from being called by
> the byte-compiler, I'd expect an assertion in it to that effect.

It's not "verboten".  Removing the binding just says that if you want to
pass adorned code to that function, it's the caller's responsability to
let-bind the variable around the call.

> Because someone, some day, might easily forget and call that function
> in the byte-compiler.

The byte-compiler already let-binds that variables, so it won't be a problem.

> Btw, why was this binding added there to begin with?

IIUC it took some trial and error to get to understand where that var
needs to be bound (as well as where is the right spot to strip the
sympos), and this is just one binding that was never removed after we
found a better place for it.


        Stefan





This bug report was last modified 1 year and 337 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.