> The issue is that locate-library returns spurious paths like ".*/tramp" orI don't see why these are necessarily spurious. Please give very
> ".*xxx/tramp.gz"
concrete examples, so as to make it crystal clear why they're spurious.
> This is both unexpected and incorrect given this function name andUnexpected to you, obviously, but I'm not convinced it's unexpected in
> spec.
general (after all, I don't remember other bug-reports in this area) and
definitely not incorrect. See the docstring of `load':
Execute a file of Lisp code named FILE.
First try FILE with `.elc' appended, then try with `.el',
then try FILE unmodified (the exact suffixes in the exact order are
determined by `load-suffixes'). Environment variable references in
[...]
Of course, there's an ambiguity about how the search is performed,
w.r.t. to whether it does:
(dolist (s suffixes) (dolist (d load-path) ...)))
or
(dolist (d load-path) (dolist (s suffixes) ...)))
We do the second, so that a compiled file in a later directory does not
override a non-compiled file in an earlier directory.
Stefan