Skip to content

Commit 046c8c9

Browse files
author
Esben Sparre Andreasen
committed
emacs: generalize parameterized annotation highlightning
1 parent 1fd9186 commit 046c8c9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

misc/emacs/ql-mode-base.el

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
(defconst ql--at-type-regex "\\_<@\\w+\\>")
1414
(defconst ql--predicate-regex "\\(\\_<\\w+\\(\\+\\|\\*\\)?\\_>\\)\\s-*(")
1515
(defconst ql--primitive-type-regex (regexp-opt '("int" "string" "float" "boolean" "date") 'symbols))
16-
(defconst ql--annotation-regex (regexp-opt '("abstract" "cached" "external" "final" "transient" "library" "private" "deprecated" "override" "query" "language" "bindingset") 'words))
17-
(defconst ql--pragma-regex "\\<pragma *\\[ *[a-z, ]*\\]")
16+
(defconst ql--annotation-regex (regexp-opt '("abstract" "cached" "external" "final" "transient" "library" "private" "deprecated" "override" "query") 'words))
17+
(defconst ql--parameterized-annotation-regex "\\<\\(pragma\\|language\\|bindingset\\) *\\[ *[a-z, ]*\\]")
1818
(defconst ql--keywords
1919
'("and" "any" "as" "asc" "avg" "boolean" "by" "class" "concat" "count" "date" "desc" "else" "exists" "extends" "false" "float" "forall" "forex" "from" "if" "implies" "import" "in" "instanceof" "int" "max" "min" "module" "not" "none" "or" "order" "predicate" "rank" "result" "select" "strictconcat" "strictcount" "strictsum" "string" "sum" "super" "then" "this" "true" "where"
2020
)
@@ -25,7 +25,7 @@
2525
(,ql--primitive-type-regex . 'font-lock-type-face)
2626
(,ql--at-type-regex 0 'font-lock-type-face)
2727
(,ql--annotation-regex . 'font-lock-preprocessor-face)
28-
(,ql--pragma-regex . 'font-lock-preprocessor-face))
28+
(,ql--parameterized-annotation-regex . 'font-lock-preprocessor-face))
2929
)
3030

3131
(defvar ql-mode-base-map

0 commit comments

Comments
 (0)