]> git.eshelyaron.com Git - emacs.git/commitdiff
Report buffer-name when local mode-line is invalid
authorRobert Pluim <rpluim@gmail.com>
Mon, 7 Mar 2022 10:26:25 +0000 (11:26 +0100)
committerRobert Pluim <rpluim@gmail.com>
Wed, 16 Mar 2022 18:05:17 +0000 (19:05 +0100)
* lisp/files.el (hack-local-variables-prop-line): Add '(buffer-name)'
to the message reporting the malformed mode-line.

lisp/files.el

index eca8cba93f2099639a1f6803b2af6a06b53c0021..a0bc5bf26267caa323b06a8d49427ab46c11d300 100644 (file)
@@ -3741,8 +3741,8 @@ return as the symbol specifying the mode."
               (while (not (or (and (eq handle-mode t) result)
                                (>= (point) end)))
                 (unless (looking-at hack-local-variable-regexp)
-                  (message "Malformed mode-line: %S"
-                            (buffer-substring-no-properties (point) end))
+                  (message "Malformed mode-line: %S in buffer %S"
+                            (buffer-substring-no-properties (point) end) (buffer-name))
                   (throw 'malformed-line nil))
                 (goto-char (match-end 0))
                 ;; There used to be a downcase here,