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: Alan Mackenzie <acm <at> muc.de>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Mattias EngdegÄrd <mattias.engdegard <at> gmail.com>, 65017 <at> debbugs.gnu.org, Eric Marsden <eric.marsden <at> risk-engineering.org>
Subject: bug#65017: 29.1; Byte compiler interaction with cl-lib function objects, removes symbol-function
Date: Thu, 3 Aug 2023 18:48:20 +0000
Hello, Stefan.

On Thu, Aug 03, 2023 at 12:41:55 -0400, Stefan Monnier wrote:
> > cl--label-convert is defined as "Special macro-expander to rename
> > (function F) references in `cl-labels'.".  What does "rename (function
> > F) references" mean?  Is the term "name" in this context defined
> > anywhere?

> `cl--label-convert` is the macro expander for (function F) used inside
> `cl-labels` so that

>     (cl-labels ((my-foo () toto))
>       #'my-foo)

> gets turned into

>     (let ((bar (lambda () toto)))
>       bar)

> So it "renames" (function my-foo) to the corresponding variable `bar`.

> But for most (function BLA) the code should be left as-is, which a macro
> can't do directly, so `cl--labels-convert-cache` is a hack which lets us
> receive a handle to the overall (function BLA) form so we can return it
> as-is rather than having to rebuild a *new* (function BLA) which would
> just make the macro-expander call us right-back.

OK, thanks.

[ .... ]

>         Stefan

-- 
Alan Mackenzie (Nuremberg, Germany).




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.