diff options
| author | Alan Mackenzie | 2016-11-24 20:34:42 +0000 |
|---|---|---|
| committer | Alan Mackenzie | 2016-11-24 20:34:42 +0000 |
| commit | b0e79741aa66bd76ee1d69d524d5a661bf7a9f9b (patch) | |
| tree | efaba783b3eda721ece40857ca4b79ed558f43ad | |
| parent | dfc5b0f65531ef71cbd2c0cc956c246ea4239612 (diff) | |
| download | emacs-b0e79741aa66bd76ee1d69d524d5a661bf7a9f9b.tar.gz emacs-b0e79741aa66bd76ee1d69d524d5a661bf7a9f9b.zip | |
Handle correctly an (undocumented) bare mode in hack-local-variables.
lisp/files.el (hack-local-variables-prop-line): When a file's first line
contains only a mode specification without the string "mode:", return the mode
symbol only when `handle-mode' is t.
| -rw-r--r-- | lisp/files.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/files.el b/lisp/files.el index 7c56f54a463..c56ff1df561 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -3250,7 +3250,7 @@ return as the symbol specifying the mode." | |||
| 3250 | nil) | 3250 | nil) |
| 3251 | ((looking-at "[ \t]*\\([^ \t\n\r:;]+\\)\\([ \t]*-\\*-\\)") | 3251 | ((looking-at "[ \t]*\\([^ \t\n\r:;]+\\)\\([ \t]*-\\*-\\)") |
| 3252 | ;; Simple form: "-*- MODENAME -*-". | 3252 | ;; Simple form: "-*- MODENAME -*-". |
| 3253 | (if (memq handle-mode '(nil t)) | 3253 | (if (eq handle-mode t) |
| 3254 | (intern (concat (match-string 1) "-mode")))) | 3254 | (intern (concat (match-string 1) "-mode")))) |
| 3255 | (t | 3255 | (t |
| 3256 | ;; Hairy form: '-*-' [ <variable> ':' <value> ';' ]* '-*-' | 3256 | ;; Hairy form: '-*-' [ <variable> ':' <value> ';' ]* '-*-' |