emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: byte compiler warnings for different Emacs versions


From: Stefan
Subject: Re: byte compiler warnings for different Emacs versions
Date: Wed, 10 Nov 2004 20:43:50 -0500
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (darwin)

> If the attached file is byte-compiled in Emacs 20 and the resulting .elc
> file is loaded in Emacs 21, then the error below results. If the same .elc
> is loaded in Emacs 20, there is no error. If the same source file is
> byte-compiled in Emacs 21 and the resulting file is loaded in Emacs 21, then
> there is no error.

The code ha a bug: it does a runtime test to decide whether to avoid using
a macro or not.  The test should be done at compile time because once the
file is compiled, without the macro you can't run it with the macro.

I.e. the comparison with emacs-version should be wrapped inside
`eval-when-compile'.  Of course it should also be replaced with a test
like (fboundp 'define-minor-mode) (but still within `eval-when-compile').


        Stefan




reply via email to

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