[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/d-mode 5691b70 069/346: Merge pull request #36 from dmakar
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/d-mode 5691b70 069/346: Merge pull request #36 from dmakarov/master |
Date: |
Sun, 29 Aug 2021 11:00:05 -0400 (EDT) |
branch: elpa/d-mode
commit 5691b703f340997ba20601a7a9fd7b71a3805d55
Merge: dea775a 781a94d
Author: Russel Winder <russel@winder.org.uk>
Commit: Russel Winder <russel@winder.org.uk>
Merge pull request #36 from dmakarov/master
new doc-comment style that recognizes /*!, //!, ///, /++, and /+! prefixes
---
d-mode.el | 27 ++++++++++++++++++++-------
1 file changed, 20 insertions(+), 7 deletions(-)
diff --git a/d-mode.el b/d-mode.el
index 49edee9..2dabd7a 100644
--- a/d-mode.el
+++ b/d-mode.el
@@ -137,16 +137,29 @@ operators."
(c-lang-defconst c-literal-start-regexp
;; Regexp to match the start of comments and string literals.
d "/[*+/]\\|\"\\|`")
-;;(c-lang-defconst c-comment-prefix-regexp d "//+\\|\\**")
-
-(c-lang-defconst c-doc-comment-start-regexp
- ;; doc comments for D use "///", "/**" or doxygen's "/*!" "//!"
- d "/\\*[*!]\\|//[/!]")
(c-lang-defconst c-block-prefix-disallowed-chars
;; Allow ':' for inherit list starters.
d (set-difference (c-lang-const c-block-prefix-disallowed-chars)
- '(?:)))
+ '(?:)))
+
+(defconst doxygen-font-lock-doc-comments
+ (let ((symbol "[a-zA-Z0-9_]+")
+ (header "^ \\* "))
+ `((,(concat header "\\(" symbol "\\):[ \t]*$")
+ 1 ,c-doc-markup-face-name prepend nil)
+ (,(concat symbol "()")
+ 0 ,c-doc-markup-face-name prepend nil)
+ (,(concat header "\\(" "@" symbol "\\):")
+ 1 ,c-doc-markup-face-name prepend nil)
+ (,(concat "[#%@]" symbol)
+ 0 ,c-doc-markup-face-name prepend nil))
+ ))
+
+(defconst doxygen-font-lock-keywords
+ `((,(lambda (limit)
+ (c-font-lock-doc-comments "/\\+[+!]\\|/\\*[*!]\\|//[/!]" limit
+ doxygen-font-lock-doc-comments)))))
;;----------------------------------------------------------------------------
@@ -456,7 +469,7 @@ operators."
(define-derived-mode d-mode d-parent-mode "D"
"Major mode for editing code written in the D Programming Language.
-See http://www.digitalmars.com/d for more information about the D language.
+See http://dlang.org for more information about the D language.
The hook `c-mode-common-hook' is run with no args at mode
initialization, then `d-mode-hook'.
- [nongnu] elpa/d-mode cca34f1 061/346: Add the mode hook definition. Fix a few spelling errors., (continued)
- [nongnu] elpa/d-mode cca34f1 061/346: Add the mode hook definition. Fix a few spelling errors., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 53efec4 063/346: Make the licence explicit in the README.md and add a copy of the licence text., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 29589e6 064/346: Line after 'else' should not be a statment-cont, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 281ea8f 020/346: Add 'delete' to c-paren-type-kwds., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 9b22a93 023/346: Declare the 2.0.6 release., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 2cb1fe0 030/346: don't highlight []* in type face, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 2f684db 037/346: Fix deadlock in imenu generator, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 701c6be 044/346: use `cc-imenu-init' rather than `setq', ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode bac805f 050/346: Fix backslashes in backquotes, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 86930c3 059/346: Rework a sentence of the README., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 5691b70 069/346: Merge pull request #36 from dmakarov/master,
ELPA Syncer <=
- [nongnu] elpa/d-mode 8a14ce4 080/346: Fix some compiler warnings., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 79940f2 085/346: Cleanup and fix test error reporting., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode fbd1f8b 089/346: Merge pull request #44 from snosov1/master, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode e19d704 090/346: Closes #21., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode a927264 092/346: Allow tests to specify lisp code and expected output., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode b4cbdfc 094/346: Workaround issue #50., ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 3e80976 097/346: recognize deprecation warnings, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 6323cd4 098/346: Recognize postfix @-keywords in function declarations for imenu, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 600c70b 108/346: Merge pull request #65 from CyberShadow/pull-20160329-054927, ELPA Syncer, 2021/08/29
- [nongnu] elpa/d-mode 3e73378 112/346: Update the badges/shields in the README., ELPA Syncer, 2021/08/29