aboutsummaryrefslogtreecommitdiff
path: root/runtime/queries/go/locals.scm
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/queries/go/locals.scm')
-rw-r--r--runtime/queries/go/locals.scm12
1 files changed, 10 insertions, 2 deletions
diff --git a/runtime/queries/go/locals.scm b/runtime/queries/go/locals.scm
index aae56257..14a6f3e4 100644
--- a/runtime/queries/go/locals.scm
+++ b/runtime/queries/go/locals.scm
@@ -1,9 +1,17 @@
; Scopes
-(block) @local.scope
+[
+ (function_declaration)
+ (type_declaration)
+ (block)
+] @local.scope
; Definitions
+(type_parameter_list
+ (parameter_declaration
+ name: (identifier) @local.definition))
+
(parameter_declaration (identifier) @local.definition)
(variadic_parameter_declaration (identifier) @local.definition)
@@ -27,4 +35,4 @@
(identifier) @local.reference
(field_identifier) @local.reference
-
+(type_identifier) @local.reference