[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#12357: 24.2; list-load-path-shadow should ignore .dir-locals.el
From: |
Johan Claesson |
Subject: |
bug#12357: 24.2; list-load-path-shadow should ignore .dir-locals.el |
Date: |
Sat, 08 Sep 2012 16:08:03 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) |
I did not think about that kind of shadowing. I agree that would also
be nice to have reported. But i think it is a different thing. Also
it could be that the user wants the lower dir-locals file to shadow the
higher one. But i guess no user wants one lisp file to shadow another
in the load-path.
Maybe a separate command could search for dir-local files shadowing
other dir-local files for a given directory or list of directories.
(I could submit such a function.)
I usually run list-load-path-shadows in the same go as compiling my
elisp directory and just like it is nice to have no compiler warnings it
is nice to have no shadow warnings.
Regards,
/Johan
Glenn Morris <rgm@gnu.org> writes:
> Johan Claesson wrote:
>
>> A minor suggestion for shadow.el. list-load-path-shadows will detect
>> if there are two lisp files with the same name in the load-path. Such
>> a clash could cause problems for normal lisp files. But i think it is
>> normal to have multiple .dir-locals.el files spread across the
>> load-path. In order to avoid false warnings list-load-path-shadows
>> could ignore the special file name .dir-locals.el.
>
> I think you are right, but if any one given directory has more than one
> dir-locals file above it in the directory tree, then the "lowest" one
> does indeed shadow all the "higher" ones. So it might be good to still
> report such cases?