highlight(swift): add upstream queries

This commit is contained in:
Christian Clason 2022-01-16 11:04:18 +01:00 committed by Stephan Seitz
parent cca7d1d671
commit f3e554ed7b
2 changed files with 148 additions and 0 deletions

18
queries/swift/locals.scm Normal file
View 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