GNU bug report logs - #59786
Allowing arbitrary expressions in cl-labels

Previous Next

Package: emacs;

Reported by: Stefan Monnier <monnier <at> iro.umontreal.ca>

Date: Fri, 2 Dec 2022 19:45:01 UTC

Severity: wishlist

Tags: patch

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: 59786 <at> debbugs.gnu.org
Cc: monnier <at> iro.umontreal.ca
Subject: bug#59786: Allowing arbitrary expressions in cl-labels
Date: Tue, 29 Oct 2024 13:28:01 +0100
Hi Stefan,

> -forms of the function body.  FUNC is defined in any BODY, as well
> +forms of the function body.  FUNC is defined in any BODY or EXP, as well
                                                            ^^^^^^
This is unfortunately not correct, e.g.

(cl-labels ((even (if (odd 5)
                      (lambda (x) (if (= x 0) t (odd (1- x))))
                    #'ignore))
            (odd  (lambda (x) (if (= x 0) nil (even (1- x))))))
         (list (even 42) (odd 42)))

~~> funcall: Symbol's function definition is void: nil

Only preceding definitions can be used in the EXP.

Dunno how useful it is at all that the EXPs can use any of the defined
functions.


Michael.




This bug report was last modified 247 days ago.

Previous Next


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