Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'runtime/queries/koto/locals.scm')
-rw-r--r--runtime/queries/koto/locals.scm30
1 files changed, 30 insertions, 0 deletions
diff --git a/runtime/queries/koto/locals.scm b/runtime/queries/koto/locals.scm
new file mode 100644
index 00000000..1886b188
--- /dev/null
+++ b/runtime/queries/koto/locals.scm
@@ -0,0 +1,30 @@
+; Scopes
+(module (_) @local.scope)
+
+(function
+ body: (_) @local.scope)
+
+; Definitions
+(assign
+ lhs: (identifier) @local.definition)
+
+(variable
+ (identifier) @local.definition)
+
+(arg
+ (identifier) @local.definition)
+
+(arg
+ (variable (identifier)) @local.definition)
+
+(import_item
+ (identifier) @local.definition)
+
+(entry_block
+ (identifier) @local.definition)
+
+(entry_inline
+ (identifier) @local.definition)
+
+; References
+(identifier) @local.reference