summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2012-09-12 22:41:46 -0400
committerGlenn Morris <rgm@gnu.org>2012-09-12 22:41:46 -0400
commit2168fe4f2ad6ea4320a0da7976294b0cdade1a20 (patch)
tree0e39b523637e3b7e350142ea9f1f9d21701beff4 /lisp/emacs-lisp
parentc0c54fbddf0784b84b04f38aabee47067a920863 (diff)
downloademacs-2168fe4f2ad6ea4320a0da7976294b0cdade1a20.tar.gz
emacs-2168fe4f2ad6ea4320a0da7976294b0cdade1a20.tar.bz2
emacs-2168fe4f2ad6ea4320a0da7976294b0cdade1a20.zip
byte-compile-warning-prefix tweak
* lisp/emacs-lisp/bytecomp.el (byte-compile-warning-prefix): If not compiling a file, try using load-file-name.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/bytecomp.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 10bc37c6dcd..c42ae21aae5 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -1016,6 +1016,10 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
((bufferp byte-compile-current-file)
(format "Buffer %s:"
(buffer-name byte-compile-current-file)))
+ ;; We might be simply loading a file that
+ ;; contains explicit calls to byte-compile functions.
+ ((stringp load-file-name)
+ (format "%s:" (file-relative-name load-file-name dir)))
(t "")))
(pos (if (and byte-compile-current-file
(integerp byte-compile-read-position))