From: Glenn Morris Date: Sun, 22 May 2011 00:34:41 +0000 (-0700) Subject: Tweak previous files.el change. X-Git-Tag: emacs-pretest-24.0.90~104^2~618^2~216 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=80614e570147005ed87f1f676c7d4926930eba6e;p=emacs.git Tweak previous files.el change. * lisp/files.el (hack-local-variables-prop-line) (hack-local-variables): In the MODE-ONLY case, return the full mode symbol, including "-mode". --- diff --git a/lisp/files.el b/lisp/files.el index f4168c107b1..1d560ace065 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -3049,7 +3049,7 @@ mode, if there is one, otherwise nil." ((looking-at "[ \t]*\\([^ \t\n\r:;]+\\)\\([ \t]*-\\*-\\)") ;; Simple form: "-*- MODENAME -*-". (if mode-only - (intern (match-string 1)))) + (intern (concat (match-string 1) "-mode")))) (t ;; Hairy form: '-*-' [ ':' ';' ]* '-*-' ;; (last ";" is optional). @@ -3077,7 +3077,8 @@ mode, if there is one, otherwise nil." (keyname (downcase (symbol-name key)))) (if mode-only (and (equal keyname "mode") - (setq result val)) + (setq result + (intern (concat (symbol-name val) "-mode")))) (or (equal keyname "coding") (condition-case nil (push (cons (if (eq key 'eval) @@ -3233,7 +3234,9 @@ is specified, and return the corresponding mode symbol, or nil." (setq val (read (current-buffer)))) (if mode-only (if (eq var 'mode) - (setq result val)) + (setq result + (intern (concat (symbol-name val) + "-mode")))) (unless (eq var 'coding) (condition-case nil (push (cons (if (eq var 'eval)