aboutsummaryrefslogtreecommitdiffstats
path: root/queries/kcl
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2023-06-12 09:54:30 -0600
committerChristian Clason <c.clason@uni-graz.at>2025-05-12 18:43:40 +0200
commit692b051b09935653befdb8f7ba8afdb640adf17b (patch)
tree167162b6b129ae04f68c5735078521a72917c742 /queries/kcl
parentfeat(c-family): inherit injections (diff)
downloadnvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.gz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.bz2
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.lz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.xz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.zst
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.zip
feat!: drop modules, general refactor and cleanup
Diffstat (limited to 'queries/kcl')
-rw-r--r--queries/kcl/folds.scm10
-rw-r--r--queries/kcl/highlights.scm201
-rw-r--r--queries/kcl/injections.scm26
3 files changed, 0 insertions, 237 deletions
diff --git a/queries/kcl/folds.scm b/queries/kcl/folds.scm
deleted file mode 100644
index 64e9e95d1..000000000
--- a/queries/kcl/folds.scm
+++ /dev/null
@@ -1,10 +0,0 @@
-[
- (protocol_stmt)
- (rule_stmt)
- (schema_stmt)
- (check_stmt)
- (if_stmt)
- (lambda_expr)
- (config_expr)
- (string)
-] @fold
diff --git a/queries/kcl/highlights.scm b/queries/kcl/highlights.scm
deleted file mode 100644
index 81b699ac2..000000000
--- a/queries/kcl/highlights.scm
+++ /dev/null
@@ -1,201 +0,0 @@
-(identifier) @variable
-
-(import_stmt
- (dotted_name
- (identifier) @module))
-
-(import_stmt
- (dotted_name
- (identifier) @module)
- (identifier) @module)
-
-(basic_type) @type.builtin
-
-(schema_type
- (dotted_name
- (identifier) @type))
-
-(schema_type
- (dotted_name
- (identifier) @module
- (identifier) @type))
-
-(schema_expr
- (identifier) @type)
-
-(protocol_stmt
- (identifier) @type)
-
-(rule_stmt
- (identifier) @type)
-
-(schema_stmt
- (identifier) @type)
-
-(lambda_expr
- (typed_parameter
- (identifier) @variable.parameter))
-
-(lambda_expr
- (identifier) @variable.parameter)
-
-(selector_expr
- (select_suffix
- (identifier) @property))
-
-(comment) @comment @spell
-
-(string) @string
-
-(escape_sequence) @string.escape
-
-(schema_stmt
- body: (block
- .
- (string
- (string_content) @string.documentation)))
-
-(decorator
- (identifier) @attribute)
-
-(call_expr
- function: (identifier) @function)
-
-(call_expr
- function: (selector_expr
- (select_suffix
- (identifier) @function)))
-
-(integer) @number
-
-(float) @number.float
-
-[
- (true)
- (false)
-] @boolean
-
-[
- (none)
- (undefined)
-] @constant.builtin
-
-"for" @keyword.repeat
-
-[
- "elif"
- "else"
- "if"
-] @keyword.conditional
-
-"lambda" @keyword.function
-
-(quant_op) @keyword.operator
-
-[
- "protocol"
- "rule"
- "schema"
- "type"
- "mixin"
-] @keyword.type
-
-"assert" @keyword.debug
-
-[
- "as"
- "import"
-] @keyword.import
-
-"check" @keyword
-
-[
- "("
- ")"
- "["
- "]"
- "{"
- "}"
-] @punctuation.bracket
-
-[
- ","
- ":"
- "."
- "?."
- "?:"
- "?"
-] @punctuation.delimiter
-
-(interpolation
- "${" @punctuation.special
- "}" @punctuation.special)
-
-[
- "+"
- "-"
- "*"
- "**"
- "/"
- "//"
- "%"
- "<<"
- ">>"
- "&"
- "|"
- "^"
- "<"
- ">"
- "~"
- "<="
- ">="
- "=="
- "!="
- "="
- "+="
- "-="
- "*="
- "**="
- "/="
- "//="
- "%="
- "<<="
- ">>="
- "&="
- "^="
- "->"
-] @operator
-
-"@" @attribute
-
-[
- "and"
- "or"
- "not"
- "in"
- "is"
-] @keyword.operator
-
-; second argument is a regex in all regex functions with at least two arguments
-(call_expr
- function: (selector_expr
- (identifier) @_regex)
- arguments: (argument_list
- (_)
- .
- (string
- (string_content) @string.regexp))
- (#eq? @_regex "regex"))
-
-; first argument is a regex in 'regex.compile' function
-(call_expr
- function: (selector_expr
- (identifier) @_regex
- (select_suffix
- (identifier) @_fn
- (#eq? @_fn "compile")))
- arguments: (argument_list
- .
- (string
- (string_content) @string.regexp))
- (#eq? @_regex "regex"))
diff --git a/queries/kcl/injections.scm b/queries/kcl/injections.scm
deleted file mode 100644
index 4e04e54d3..000000000
--- a/queries/kcl/injections.scm
+++ /dev/null
@@ -1,26 +0,0 @@
-(call_expr
- function: (selector_expr
- (identifier) @_regex)
- arguments: (argument_list
- (_)
- .
- (string
- (string_content) @injection.content))
- (#eq? @_regex "regex")
- (#set! injection.language "regex"))
-
-(call_expr
- function: (selector_expr
- (identifier) @_regex
- (select_suffix
- (identifier) @_fn
- (#eq? @_fn "compile")))
- arguments: (argument_list
- .
- (string
- (string_content) @injection.content))
- (#eq? @_regex "regex")
- (#set! injection.language "regex"))
-
-((comment) @injection.content
- (#set! injection.language "comment"))