Skip to content

Commit

Permalink
feat(scala): add in local variables queries
Browse files Browse the repository at this point in the history
This syncs the queries that were updated in tree-sitter/tree-sitter-scala#196.
  • Loading branch information
ckipp01 committed Mar 27, 2023
1 parent e559b6f commit be4ab54
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions queries/scala/locals.scm
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
(template_body) @local.scope
(lambda_expression) @local.scope

(function_declaration
name: (identifier) @local.definition) @local.scope

(function_definition
name: (identifier) @local.definition)

(parameter
name: (identifier) @local.definition)

(binding
name: (identifier) @local.definition)

(val_definition
pattern: (identifier) @local.definition)

(var_definition
pattern: (identifier) @local.definition)

(val_declaration
name: (identifier) @local.definition)

(var_declaration
name: (identifier) @local.definition)

(identifier) @local.reference

0 comments on commit be4ab54

Please sign in to comment.