[Top][All Lists]

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

Re: mh-e/mh-acros.el advices `require' incorrectly

From: Stefan Monnier
Subject: Re: mh-e/mh-acros.el advices `require' incorrectly
Date: Sat, 14 Jan 2006 12:47:37 -0500
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

>     --- orig/lisp/emacs-lisp/bytecomp.el
>     +++ mod/lisp/emacs-lisp/bytecomp.el
>     @@ -1640,6 +1640,12 @@
>        ;; Force logging of the file name for each file compiled.
>        (setq byte-compile-last-logged-file nil)
>        (let ((byte-compile-current-file filename)
>     +        ;; Prefer source files over compiled files.  This is so that when
>     +        ;; several files are changed and recompiled, each new file is
>     +        ;; properly recompiled with the new macros in the other new 
> files.
>     +        (load-suffixes (sort (copy-sequence load-suffixes)
>     +                             (lambda (s1 s2) (and (string-match 
> "\\.elc\\b" s2)
>     +                                             (string-match "\\.el\\b" 
> s1)))))
>           (set-auto-coding-for-load t)
>           target-file input-buffer output-buffer
>           byte-compile-dest-file)

> That creates an inconsistency.  If it were a reliable solution to the
> problem, that could justify the inconsistency.  But it isn't reliable,
> because if the file require'd was already loaded in bytecode outside
> the compiler, this won't reload it.

Indeed, it's just a minor convenience hack.

> For the same reason, the advice in mh-e.el is not a good solution
> (even disregarding that it is a bad thing for parts of Emacs to
> advise other parts).

100% agreement.


reply via email to

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