diff options
author | Hong Xu <hong@topbug.net> | 2019-07-07 01:09:50 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2019-07-09 14:50:19 (GMT) |
commit | 8e1664d108a183a9e1e53a3a42bc58a2a0104d60 (patch) | |
tree | fa280ae0bf8f5e6acef76b60bc4c33cd84a6821c /Auxiliary | |
parent | b9c4d26c5d5627a95eb40c4fcaddee763c446986 (diff) | |
download | CMake-8e1664d108a183a9e1e53a3a42bc58a2a0104d60.zip CMake-8e1664d108a183a9e1e53a3a42bc58a2a0104d60.tar.gz CMake-8e1664d108a183a9e1e53a3a42bc58a2a0104d60.tar.bz2 |
cmake-mode.el: Drop support for Emacs < 24
The `cmake--parent-mode` alias exists only for compatibility and breaks
Emacs packages and scripts that make use of `prog-mode-hook` because
Emacs does not examine whether the parent mode is an alias or not.
Remove the alias and require Emacs 24 or higher.
Emacs 24 was released in 2012 and this is already 2019, thus the loss to
drop support for versions < 24 is negligible.
Diffstat (limited to 'Auxiliary')
-rw-r--r-- | Auxiliary/cmake-mode.el | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/Auxiliary/cmake-mode.el b/Auxiliary/cmake-mode.el index e4fa6c1..caaf0d5 100644 --- a/Auxiliary/cmake-mode.el +++ b/Auxiliary/cmake-mode.el @@ -1,5 +1,7 @@ ;;; cmake-mode.el --- major-mode for editing CMake sources +;; Package-Requires: ((emacs "24.1")) + ; Distributed under the OSI-approved BSD 3-Clause License. See accompanying ; file Copyright.txt or https://cmake.org/licensing for details. @@ -224,17 +226,11 @@ the indentation. Otherwise it retains the same position on the line" ;; (defvar cmake-mode-hook nil) -;------------------------------------------------------------------------------ - -;; For compatibility with Emacs < 24 -(defalias 'cmake--parent-mode - (if (fboundp 'prog-mode) 'prog-mode 'fundamental-mode)) - ;;------------------------------------------------------------------------------ ;; Mode definition. ;; ;;;###autoload -(define-derived-mode cmake-mode cmake--parent-mode "CMake" +(define-derived-mode cmake-mode prog-mode "CMake" "Major mode for editing CMake source files." ; Setup font-lock mode. |