diff options
| author | Pham Huy Hoang <hoangtun0810@gmail.com> | 2024-01-06 15:05:50 +0900 |
|---|---|---|
| committer | Christian Clason <c.clason@uni-graz.at> | 2024-01-19 16:58:37 +0100 |
| commit | 57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9 (patch) | |
| tree | 70bf645539882b88e6fa129cefd30986b89bbac3 /queries/ocamllex | |
| parent | ci: add query lint job (diff) | |
| download | nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar.gz nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar.bz2 nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar.lz nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar.xz nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.tar.zst nvim-treesitter-57a8acf0c4ed5e7f6dda83c3f9b073f8a99a70f9.zip | |
chore: query formatting
Diffstat (limited to 'queries/ocamllex')
| -rw-r--r-- | queries/ocamllex/highlights.scm | 60 | ||||
| -rw-r--r-- | queries/ocamllex/injections.scm | 4 |
2 files changed, 47 insertions, 17 deletions
diff --git a/queries/ocamllex/highlights.scm b/queries/ocamllex/highlights.scm index 6a5088710..2556aa4c2 100644 --- a/queries/ocamllex/highlights.scm +++ b/queries/ocamllex/highlights.scm @@ -1,40 +1,70 @@ ; Allow OCaml highlighter - (ocaml) @none ; Regular expressions - (regexp_name) @variable -[(eof) (any)] @constant +[ + (eof) + (any) +] @constant (character) @character (string) @string + (escape_sequence) @string.escape -(character_set "^" @punctuation.special) -(character_range "-" @punctuation.delimiter) +(character_set + "^" @punctuation.special) -(regexp_difference ["#"] @operator) -(regexp_repetition ["?" "*" "+"] @operator) -(regexp_alternative ["|"] @operator) +(character_range + "-" @punctuation.delimiter) -; Rules +(regexp_difference + "#" @operator) + +(regexp_repetition + [ + "?" + "*" + "+" + ] @operator) + +(regexp_alternative + "|" @operator) +; Rules (lexer_entry_name) @function + (lexer_argument) @variable.parameter -(lexer_entry ["=" "|"] @punctuation.delimiter) +(lexer_entry + [ + "=" + "|" + ] @punctuation.delimiter) ; keywords - -["and" "as" "let" "parse" "refill" "rule" "shortest"] @keyword +[ + "and" + "as" + "let" + "parse" + "refill" + "rule" + "shortest" +] @keyword ; Punctuation - -["[" "]" "(" ")" "{" "}"] @punctuation.bracket +[ + "[" + "]" + "(" + ")" + "{" + "}" +] @punctuation.bracket ; Misc - (comment) @comment @spell diff --git a/queries/ocamllex/injections.scm b/queries/ocamllex/injections.scm index ed1d9302a..ecc577d40 100644 --- a/queries/ocamllex/injections.scm +++ b/queries/ocamllex/injections.scm @@ -1,5 +1,5 @@ ((ocaml) @injection.content - (#set! injection.language "ocaml")) + (#set! injection.language "ocaml")) ((comment) @injection.content - (#set! injection.language "comment")) + (#set! injection.language "comment")) |
