GNU bug report logs - #77048
30.1; Macro `cl-load-time-value` malfunctioning at compile-time and runtime

Previous Next

Package: emacs;

Reported by: Bohong Huang <bohonghuang <at> qq.com>

Date: Sun, 16 Mar 2025 12:10:03 UTC

Severity: normal

Found in version 30.1

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Bohong Huang <bohonghuang <at> qq.com>, Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 77048 <at> debbugs.gnu.org
Subject: bug#77048: 30.1; Macro `cl-load-time-value` malfunctioning at compile-time and runtime
Date: Sun, 16 Mar 2025 14:30:53 +0200
> Date: Sun, 16 Mar 2025 15:21:06 +0800
> From:  Bohong Huang via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> 
> 
> Hello Emacs maintainers,  
> 
> When using `cl-load-time-value` from `cl-lib`, I encountered an issue
> where the macro fails during both byte-compilation and runtime:
> 
> `reference to free variable ‘--cl-load-time--0’`  

I'm guessing your Lisp file doesn't have the lexical-binding cookie.
If it did, you should have seen a different warning.

> I find this macro is quite useful for performing compile-time
> computations within a function body without polluting global variable
> names and relying on `cl-macrolet`.

Stefan, any comments?




This bug report was last modified 90 days ago.

Previous Next


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