emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: cl-byte-compile-compiler-macro


From: Stefan Monnier
Subject: Re: cl-byte-compile-compiler-macro
Date: Sat, 08 Apr 2006 11:09:36 -0400
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

>        (eval-when-compile . (lambda (&rest body)
>                              (list 'quote
>     -                          (byte-compile-eval (byte-compile-top-level
>     -                                              (cons 'progn body))))))
>     +                          (byte-compile-eval (cons 'progn body)))))

> What is the reason for removing byte-compile-top-level?

Sorry, this part of the patch was a mistake (it's a local change that
I failed to remove before sending the email).

> Was the call superfluous before?

Yes, I think it's superfluous, and more importantly it can introduce "bugs"
if the code is too large to be byte-compiled (causes too deep a recursion).
I bumped into this at some point where I had a defconst whose (constant)
value was built with a deep backquoted expression: the byte-compiler would
choke on it, so I figured "well it's a constant anyway, so let's eval it
before byte-compiling", but wrapping it in eval-when-compile didn't make
a difference because the content is byte-compiled anyway.

>     +                    (or (fboundp handler)
>     +                        (progn (byte-compile-warn
>     +                                "Ignoring byte-compiler handler `%S'" 
> handler)
>     +                               nil))

> I don't think this should warn.  This warning would be generated
> whenever you compile calls to these functions and CL is not loaded.
> The warning isn't useful, because it describes a circumstance which
> does not mean anything is wrong.

> So please don't add the warning.

OK,


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]