mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-20 04:10:06 -04:00
chore: query formatting
This commit is contained in:
parent
79975d6557
commit
57a8acf0c4
674 changed files with 18466 additions and 12648 deletions
|
|
@ -1,15 +1,34 @@
|
|||
; let bindings
|
||||
(let_expression (binding_set (binding . (attrpath) @local.definition.var))) @local.scope
|
||||
(let_expression
|
||||
(binding_set
|
||||
(binding
|
||||
.
|
||||
(attrpath) @local.definition.var))) @local.scope
|
||||
|
||||
; rec attrsets
|
||||
(rec_attrset_expression (binding_set (binding . (attrpath) @local.definition.field))) @local.scope
|
||||
(rec_attrset_expression
|
||||
(binding_set
|
||||
(binding
|
||||
.
|
||||
(attrpath) @local.definition.field))) @local.scope
|
||||
|
||||
; functions and parameters
|
||||
(function_expression . [
|
||||
(function_expression
|
||||
.
|
||||
[
|
||||
(identifier) @local.definition.parameter
|
||||
(formals (formal . (identifier) @local.definition.parameter))
|
||||
]) @local.scope
|
||||
((formals) "@" (identifier) @local.definition.parameter) ; I couldn't get this to work properly inside the (function)
|
||||
(formals
|
||||
(formal
|
||||
.
|
||||
(identifier) @local.definition.parameter))
|
||||
]) @local.scope
|
||||
|
||||
(variable_expression (identifier) @local.reference)
|
||||
(inherited_attrs attr: (identifier) @local.reference)
|
||||
((formals)
|
||||
"@"
|
||||
(identifier) @local.definition.parameter) ; I couldn't get this to work properly inside the (function)
|
||||
|
||||
(variable_expression
|
||||
(identifier) @local.reference)
|
||||
|
||||
(inherited_attrs
|
||||
attr: (identifier) @local.reference)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue