mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-21 21:00:08 -04:00
java locals.scm - fix definitions
This commit is contained in:
parent
c8d871fc14
commit
f0d0fbfbb2
1 changed files with 8 additions and 4 deletions
|
|
@ -4,7 +4,7 @@
|
|||
(method_declaration) @scope
|
||||
(block) @scope
|
||||
; 3 captures for `if` - if+else, if only, else only
|
||||
(if_statement) @scope
|
||||
(if_statement) @scope
|
||||
(if_statement
|
||||
body: (_)) @scope
|
||||
(if_statement
|
||||
|
|
@ -24,10 +24,14 @@
|
|||
name: (identifier) @definition.class)
|
||||
(method_declaration
|
||||
name: (identifier) @definition.method)
|
||||
(local_variable_declaration) @definition.var
|
||||
(field_declaration) @definition.field
|
||||
(local_variable_declaration
|
||||
declarator: (variable_declarator
|
||||
name: (identifier) @definition.var))
|
||||
(field_declaration
|
||||
declarator: (variable_declarator
|
||||
name: (identifier) @definition.field))
|
||||
(import_declaration) @definition.import
|
||||
|
||||
;; REFERENCE
|
||||
; REFERENCES
|
||||
(identifier) @reference
|
||||
(type_identifier) @reference
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue