mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-17 10:50:06 -04:00
highlight(swift): add upstream queries
This commit is contained in:
parent
cca7d1d671
commit
f3e554ed7b
2 changed files with 148 additions and 0 deletions
18
queries/swift/locals.scm
Normal file
18
queries/swift/locals.scm
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
(import_declaration (identifier) @definition.import)
|
||||
(function_declaration name: (simple_identifier) @definition.function)
|
||||
|
||||
; Scopes
|
||||
[
|
||||
(statements)
|
||||
(for_statement)
|
||||
(while_statement)
|
||||
(repeat_while_statement)
|
||||
(do_statement)
|
||||
(if_statement)
|
||||
(guard_statement)
|
||||
(switch_statement)
|
||||
(property_declaration)
|
||||
(function_declaration)
|
||||
(class_declaration)
|
||||
(protocol_declaration)
|
||||
] @scope
|
||||
Loading…
Add table
Add a link
Reference in a new issue