From: Lars Ingebrigtsen Date: Mon, 18 Apr 2022 08:37:14 +0000 (+0200) Subject: Fix major-mode setting regression when there's a mode: cookie X-Git-Tag: emacs-28.1.90~123 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=4684b8e62f;p=emacs.git Fix major-mode setting regression when there's a mode: cookie * lisp/files.el (hack-local-variables): Fix regression in setting the major mode when there are mode: cookies in the file (bug#54993). Do not merge to master. --- diff --git a/lisp/files.el b/lisp/files.el index d8e7989672a..30e8da4da37 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -3887,7 +3887,7 @@ inhibited." (with-demoted-errors "Directory-local variables error: %s" ;; Note this is a no-op if enable-local-variables is nil. (hack-dir-local-variables)) - (let ((result (append (hack-local-variables--find-variables) + (let ((result (append (hack-local-variables--find-variables handle-mode) (hack-local-variables-prop-line)))) (if (and enable-local-variables (not (inhibit-local-variables-p)))