macroexp--warn-and-return message tweak (bug#13132)
authorGlenn Morris <rgm@gnu.org>
Fri, 14 Dec 2012 21:27:39 +0000 (16:27 -0500)
committerGlenn Morris <rgm@gnu.org>
Fri, 14 Dec 2012 21:27:39 +0000 (16:27 -0500)
* lisp/emacs-lisp/macroexp.el (macroexp--warn-and-return):
Try to include filename in non-bytecomp warning.

lisp/ChangeLog
lisp/emacs-lisp/macroexp.el

index 15cdb5c..0517a66 100644 (file)
@@ -1,3 +1,8 @@
+2012-12-14  Glenn Morris  <rgm@gnu.org>
+
+       * emacs-lisp/macroexp.el (macroexp--warn-and-return):
+       Try to include filename in non-bytecomp warning.  (Bug#13132)
+
 2012-12-14  Paul Eggert  <eggert@cs.ucla.edu>
 
        Fix permissions bugs with setgid directories etc. (Bug#13125)
index 2a37307..7a1a21f 100644 (file)
@@ -124,7 +124,10 @@ and also to avoid outputting the warning during normal execution."
          (macroexp--funcall-if-compiled ',when-compiled)
          ,form))
      (t
-      (message "%s" msg)
+      (message "%s%s" (if (stringp load-file-name)
+                          (concat (file-relative-name load-file-name) ": ")
+                        "")
+               msg)
       form))))
 
 (defun macroexp--obsolete-warning (fun obsolescence-data type)