mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-14 17:30:08 -04:00
Use @symbol in clojure in commonlisp
This commit is contained in:
parent
64f13eace5
commit
007aa7ff21
3 changed files with 14 additions and 13 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
(dis_expr) @comment
|
(dis_expr) @comment
|
||||||
|
|
||||||
(kwd_lit) @type
|
(kwd_lit) @symbol
|
||||||
|
|
||||||
(str_lit) @string
|
(str_lit) @string
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
(sym_lit) @variable
|
(sym_lit) @variable
|
||||||
|
|
||||||
;; A highlighting for functions/macros in th cl namespace is available in theHamsta/nvim-treesitter-commonlisp
|
;; A highlighting for functions/macros in th cl namespace is available in theHamsta/nvim-treesitter-commonlisp
|
||||||
;(list_lit . (sym_lit) @function.builtin (#cl-standard-symbol? @function.builtin))
|
;(list_lit . (sym_lit) @function.builtin (#cl-standard-function? @function.builtin))
|
||||||
|
;(list_lit . (sym_lit) @function.builtin (#cl-standard-macro? @function.macro))
|
||||||
|
|
||||||
(dis_expr) @comment
|
(dis_expr) @comment
|
||||||
|
|
||||||
|
|
@ -12,13 +13,13 @@
|
||||||
lambda_list: (list_lit (sym_lit) @parameter))
|
lambda_list: (list_lit (sym_lit) @parameter))
|
||||||
(defun_header
|
(defun_header
|
||||||
keyword: (defun_keyword "defmethod")
|
keyword: (defun_keyword "defmethod")
|
||||||
lambda_list: (list_lit (list_lit . (sym_lit) . (sym_lit) @type)))
|
lambda_list: (list_lit (list_lit . (sym_lit) . (sym_lit) @symbol)))
|
||||||
(defun_header
|
(defun_header
|
||||||
lambda_list: (list_lit (list_lit . (sym_lit) @parameter . (_))))
|
lambda_list: (list_lit (list_lit . (sym_lit) @parameter . (_))))
|
||||||
(defun_header
|
(defun_header
|
||||||
specifier: (sym_lit) @type)
|
specifier: (sym_lit) @symbol)
|
||||||
|
|
||||||
[":" "."] @punctuation.special
|
[":" "::" "."] @punctuation.special
|
||||||
|
|
||||||
[
|
[
|
||||||
(accumulation_verb)
|
(accumulation_verb)
|
||||||
|
|
@ -50,10 +51,10 @@
|
||||||
] @function.macro
|
] @function.macro
|
||||||
"=" @operator
|
"=" @operator
|
||||||
|
|
||||||
(include_reader_macro) @type
|
(include_reader_macro) @symbol
|
||||||
["#C" "#c"] @number
|
["#C" "#c"] @number
|
||||||
|
|
||||||
[(kwd_lit) (self_referential_reader_macro)] @type
|
[(kwd_lit) (self_referential_reader_macro)] @symbol
|
||||||
|
|
||||||
(package_lit
|
(package_lit
|
||||||
package: (_) @namespace)
|
package: (_) @namespace)
|
||||||
|
|
@ -117,10 +118,10 @@
|
||||||
(#match? @constant "^[+].+[+]$"))
|
(#match? @constant "^[+].+[+]$"))
|
||||||
|
|
||||||
(var_quoting_lit
|
(var_quoting_lit
|
||||||
marker: "#'" @type
|
marker: "#'" @symbol
|
||||||
value: (_) @type)
|
value: (_) @symbol)
|
||||||
|
|
||||||
["#" "#p" "#P"] @type
|
["#" "#p" "#P"] @symbol
|
||||||
|
|
||||||
(list_lit
|
(list_lit
|
||||||
.
|
.
|
||||||
|
|
@ -134,8 +135,8 @@
|
||||||
(#match? @operator "^([+*-+=<>]|<=|>=|/=)$"))
|
(#match? @operator "^([+*-+=<>]|<=|>=|/=)$"))
|
||||||
|
|
||||||
|
|
||||||
((sym_lit) @type
|
((sym_lit) @symbol
|
||||||
(#match? @type "^[&]"))
|
(#match? @symbol "^[&]"))
|
||||||
|
|
||||||
[(array_dimension) "#0A" "#0a"] @number
|
[(array_dimension) "#0A" "#0a"] @number
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@
|
||||||
|
|
||||||
(list_lit
|
(list_lit
|
||||||
.
|
.
|
||||||
(sym_lit) @_let (#match? @_let "(cl:|alexandria)?(with-gensyms|dotimes|with-foreign-object)")
|
(sym_lit) @_let (#match? @_let "(cl:|alexandria:)?(with-gensyms|dotimes|with-foreign-object)")
|
||||||
.
|
.
|
||||||
(list_lit . (sym_lit) @definition.var)) @scope
|
(list_lit . (sym_lit) @definition.var)) @scope
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue