emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs-25 2c0dc9f: Fix warning message in hack-local-variab


From: Eli Zaretskii
Subject: [Emacs-diffs] emacs-25 2c0dc9f: Fix warning message in hack-local-variables
Date: Wed, 03 Feb 2016 17:49:50 +0000

branch: emacs-25
commit 2c0dc9fa70dcde56f68db6e72309f995e5c0e6e0
Author: Noam Postavsky <address@hidden>
Commit: Eli Zaretskii <address@hidden>

    Fix warning message in hack-local-variables
    
    * lisp/files.el (hack-local-variables): use 'thisbuf' to reference
    the original buffer name in the warning message.  (Bug#21681)
---
 lisp/files.el |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/lisp/files.el b/lisp/files.el
index 3898dff..72c2752 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -3426,7 +3426,11 @@ local variables, but directory-local variables may still 
be applied."
                                   (format-message
                                    "%s: `lexical-binding' at end of file 
unreliable"
                                    (file-name-nondirectory
-                                    (or buffer-file-name ""))))))
+                                    ;; We are called from
+                                    ;; 'with-temp-buffer', so we need
+                                    ;; to use 'thisbuf's name in the
+                                    ;; warning message.
+                                    (or (buffer-file-name thisbuf) ""))))))
                              (t
                               (ignore-errors
                                 (push (cons (if (eq var 'eval)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]