emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/d-mode 09745ba 175/346: Merge pull request #87 from CyberS


From: ELPA Syncer
Subject: [nongnu] elpa/d-mode 09745ba 175/346: Merge pull request #87 from CyberShadow/emacs-24-plus
Date: Sun, 29 Aug 2021 11:00:24 -0400 (EDT)

branch: elpa/d-mode
commit 09745ba713e08a02fd81c01824aefa6731992a6f
Merge: 8d0ed04 8cf1ec5
Author: Vladimir Panteleev <github.private@thecybershadow.net>
Commit: GitHub <noreply@github.com>

    Merge pull request #87 from CyberShadow/emacs-24-plus
    
    Drop support for Emacs < 24.3
---
 README.md |  2 +-
 d-mode.el | 23 +++++++++++------------
 2 files changed, 12 insertions(+), 13 deletions(-)

diff --git a/README.md b/README.md
index 31b37a2..d5fe2bd 100644
--- a/README.md
+++ b/README.md
@@ -8,7 +8,7 @@
 
 An Emacs major mode for editing D code.
 
-This mode is currently known to work with Emacs 24 and 25, and believed to 
work with Emacs 23.
+This mode is currently known to work with Emacs 24 and 25.
 
 The best way of installing this major mode, at least for Emacs 24, is to use 
the packaging system. Add MELPA
 or MELPA Stable to the list of repositories to access this mode. For those who 
want only formal, tagged
diff --git a/d-mode.el b/d-mode.el
index 95d0ed1..1685476 100644
--- a/d-mode.el
+++ b/d-mode.el
@@ -7,8 +7,9 @@
 ;; Maintainer:  Russel Winder <russel@winder.org.uk>
 ;;              Vladimir Panteleev <vladimir@thecybershadow.net>
 ;; Created:  March 2007
-;; Version:  201802141931
+;; Version:  201804041719
 ;; Keywords:  D programming language emacs cc-mode
+;; Package-Requires: ((emacs "24.3"))
 
 ;;;; NB Version number is date and time yyyymmddhhMM UTC.
 ;;;; A hook to update it automatically on save is available here:
@@ -77,11 +78,13 @@
 ;;   "Symbol's value as variable is void: 
compilation-error-regexp-alist-alist" errors
 (require 'compile)
 
+;; Work around Emacs (cc-mode) bug #18845
+(eval-when-compile
+  (when (and (= emacs-major-version 24) (>= emacs-minor-version 4))
+    (require 'cl)))
+
 ;; The set-difference function is used from the Common Lisp extensions.
-;; Note that this line produces a compilation warning in Emacs 24 and newer,
-;; however the replacement (cl-seq.el for our use case) was introduced
-;; in the same major version.
-(require 'cl)
+(require 'cl-lib)
 
 ;; Used to specify regular expressions in a sane way.
 (require 'rx)
@@ -171,8 +174,8 @@ operators."
 
 (c-lang-defconst c-block-prefix-disallowed-chars
   ;; Allow ':' for inherit list starters.
-  d (set-difference (c-lang-const c-block-prefix-disallowed-chars)
-                    '(?:)))
+  d (cl-set-difference (c-lang-const c-block-prefix-disallowed-chars)
+                      '(?:)))
 
 (defconst doxygen-font-lock-doc-comments
   (let ((symbol "[a-zA-Z0-9_]+")
@@ -715,12 +718,8 @@ The expression is added to 
`compilation-error-regexp-alist' and
   :type 'hook
   :group 'c)
 
-;; For compatibility with Emacs < 24
-(defalias 'd-parent-mode
-  (if (fboundp 'prog-mode) 'prog-mode 'fundamental-mode))
-
 ;;;###autoload
-(define-derived-mode d-mode d-parent-mode "D"
+(define-derived-mode d-mode prog-mode "D"
   "Major mode for editing code written in the D Programming Language.
 
 See http://dlang.org for more information about the D language.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]