branch: elpa/d-mode
commit 68ee0fe1beb44313cbb6abc112490c002fa1d551
Author: Roy Crihfield <[email protected]>
Commit: Roy Crihfield <[email protected]>
Parent mode is conditional for compatibility
---
d-mode.el | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/d-mode.el b/d-mode.el
index e2d17f2..11ae816 100644
--- a/d-mode.el
+++ b/d-mode.el
@@ -367,6 +367,10 @@ operators."
;;----------------------------------------------------------------------------
;;;###autoload (add-to-list 'auto-mode-alist '("\\.d[i]?\\'" . d-mode))
+;; For compatibility with Emacs < 24
+(defalias 'd-parent-mode
+ (if (functionp 'prog-mode) 'prog-mode 'fundamental-mode))
+
;;;###autoload
(define-derived-mode d-mode prog-mode "D"
"Major mode for editing code written in the D Programming Language.