1
Files
flake-nixinator/config/neovim/store/treesitter-parsers/queries/ocamllex/highlights.scm

46 lines
692 B
Scheme

; Regular expressions
;--------------------
(regexp_name) @variable
[(any) (eof)] @constant
[(string) (character)] @string
(escape_sequence) @escape
(character_set "^" @punctuation.special)
(character_range "-" @punctuation.delimiter)
(regexp_difference "#" @operator)
(regexp_repetition ["*" "+" "?"] @operator)
(regexp_alternative "|" @operator)
; Rules
;------
(lexer_entry_name) @function
(lexer_argument) @variable.parameter
(lexer_entry ["=" "|"] @punctuation.delimiter)
; Keywords
;---------
["and" "as" "parse" "refill" "rule" "shortest"] @keyword
; Punctuation
;------------
["[" "]" "(" ")" "{" "}"] @punctuation.bracket
; Comments
;---------
(comment) @comment