[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
eval-after-load changes
From: |
Romain Francoise |
Subject: |
eval-after-load changes |
Date: |
Thu, 25 May 2006 12:46:15 +0200 |
There's a bug in the changes you installed yesterday: `eval-after-load'
forms get evaluated immediately if the last word of the name of the file
they're contained in matches the FILE arg of the e-a-l form.
To reproduce this bug, create a file named `this-is-not-ibuffer.el' that
contains the following:
(eval-after-load "ibuffer"
'(progn
(add-to-list 'ibuffer-maybe-show-predicates "\\.newsrc")))
Then start Emacs with emacs -q and try to load the file. Emacs signals
the following error:
| progn: Symbol's value as variable is void: ibuffer-maybe-show-predicates
I.e. it tried to evaluate the eval-after-load form, even though ibuffer
isn't loaded. This is because the new `do-after-load-evaluation'
function contains this code:
(string-match (car a-l-element) abs-file)
which runs as:
(string-match "\\<ibuffer\\(\\.elc\\|\\.el\\)?\\(\\.gz\\)?\\'"
"/tmp/this-is-not-ibuffer.el")
which returns 17, and not nil. I think the regexp should begin with
\\`, not \\<, but since there's apparently special provisions to make it
use \\<, I'm not sure what a good fix could be.
(This bug makes my Emacs configuration completely broken.)
Thanks,
--
Romain Francoise <address@hidden> | The sea! the sea! the open
it's a miracle -- http://orebokech.com/ | sea! The blue, the fresh, the
| ever free! --Bryan W. Procter
- eval-after-load changes,
Romain Francoise <=