[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
"load-file" surreptitiously pushes directories onto load-path.
From: |
Alan Mackenzie |
Subject: |
"load-file" surreptitiously pushes directories onto load-path. |
Date: |
9 Apr 2007 09:53:40 +0200 |
Date: |
Sun, 8 Apr 2007 23:10:24 +0100 |
User-agent: |
Mutt/1.5.9i |
Hi, Emacs!
Start a modern Emacs with
# emacs -Q
In *scratch*, do
C-u M-: load-path
Follow this up with
M-x load-file ~/cc-mode-5.31.n/tests/000tests.elc
and repeat
C-u M-: load-path
It will be seen that load-file has pushed the element
"/home/acm/cc-mode-5.31.n" onto the front of load-path. This is surely
a bug. And even if it's not, it ought to be!
I think it's a serious bug. It can lead hackers to testing code which
is in a different directory from what they think. It has done exactly
that to me for an extended period.
I've had a quick look through the Elisp manual, without finding this
behaviour described.
As a matter of interest, this bug is in Emacs 21. It is very old.
I might try and track it down tomorrow.
--
Alan Mackenzie (Ittersbach, Germany).
- "load-file" surreptitiously pushes directories onto load-path.,
Alan Mackenzie <=