From: Noam Postavsky <npostavs@gmail.com>
To: 21681@debbugs.gnu.org
Subject: bug#21681: [PATCH] Fix formatting of lexical-binding at eof warning
Date: Tue, 13 Oct 2015 18:51:28 -0400 [thread overview]
Message-ID: <CAM-tV--DRVNBZBqdAMd9hXgUTe6Z_TFwHiMN=S=z3+UB8QhgPA@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 168 bytes --]
Before:
Warning (:warning): : ‘lexical-binding’ at end of file unreliable
After:
Warning (files): foo.el: ‘lexical-binding’ at end of file unreliable
[-- Attachment #2: 0001-Fix-formatting-of-lexical-binding-at-eof-warning.patch --]
[-- Type: text/x-diff, Size: 1275 bytes --]
From 3c3c1bd1d5672930b95d9ac00ba7e48636b7ff7f Mon Sep 17 00:00:00 2001
From: Noam Postavsky <npostavs@users.sourceforge.net>
Date: Tue, 13 Oct 2015 18:29:56 -0400
Subject: [PATCH] Fix formatting of lexical-binding at eof warning
* lisp/files.el (hack-local-variables): Get buffer name from the
visiting buffer, and pass 'files as first arg to `display-warning'.
---
lisp/files.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lisp/files.el b/lisp/files.el
index 8565aa8..d979a42 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -3418,11 +3418,11 @@ (defun hack-local-variables (&optional mode-only)
(unless hack-local-variables--warned-lexical
(setq hack-local-variables--warned-lexical t)
(display-warning
- :warning
+ 'files
(format-message
"%s: `lexical-binding' at end of file unreliable"
(file-name-nondirectory
- (or buffer-file-name ""))))))
+ (or (buffer-file-name thisbuf) ""))))))
(t
(ignore-errors
(push (cons (if (eq var 'eval)
--
2.5.3
next reply other threads:[~2015-10-13 22:51 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-13 22:51 Noam Postavsky [this message]
2015-10-14 16:28 ` bug#21681: [PATCH] Fix formatting of lexical-binding at eof warning Eli Zaretskii
2015-10-14 16:56 ` Noam Postavsky
2015-10-14 17:42 ` Eli Zaretskii
2015-10-14 17:47 ` Noam Postavsky
2015-10-14 17:53 ` Eli Zaretskii
2015-10-14 19:46 ` Eli Zaretskii
2015-10-15 2:30 ` Noam Postavsky
2015-10-31 22:36 ` Noam Postavsky
2016-01-24 18:43 ` Noam Postavsky
2016-01-24 18:51 ` Eli Zaretskii
2016-01-24 19:34 ` Noam Postavsky
2016-01-25 17:07 ` Eli Zaretskii
2016-01-31 15:56 ` Noam Postavsky
2016-02-03 17:49 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAM-tV--DRVNBZBqdAMd9hXgUTe6Z_TFwHiMN=S=z3+UB8QhgPA@mail.gmail.com' \
--to=npostavs@gmail.com \
--cc=21681@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).