aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl Hiner <karl.hiner@gmail.com>2024-02-23 01:41:28 -0500
committerGitHub <noreply@github.com>2024-02-23 15:41:28 +0900
commita29058fe8b4ba291a63422073e5bd3d8920942ac (patch)
treebe90865374c261e4f9ca92680f6c4a0045584be1
parentUpdate README (diff)
downloadnvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar.gz
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar.bz2
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar.lz
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar.xz
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.tar.zst
nvim-treesitter-a29058fe8b4ba291a63422073e5bd3d8920942ac.zip
feat(faust): better highlighting of function calls, built-in variables, and member access
-rw-r--r--lockfile.json2
-rw-r--r--queries/faust/highlights.scm24
2 files changed, 14 insertions, 12 deletions
diff --git a/lockfile.json b/lockfile.json
index 5a2d278b5..a16ecc14f 100644
--- a/lockfile.json
+++ b/lockfile.json
@@ -159,7 +159,7 @@
"revision": "a52579670e2b14ec03d410c3c980fafaf6d659c4"
},
"faust": {
- "revision": "4a8ada6eb1ac2ade8f310e3822b86301f439e463"
+ "revision": "f3b9274514b5f9bf6b0dd4a01c30f9cc15c58bc4"
},
"fennel": {
"revision": "9265a7d635d2f82a10738b9ad65ba8dd8bd4a84a"
diff --git a/queries/faust/highlights.scm b/queries/faust/highlights.scm
index 012562971..df2c3e70a 100644
--- a/queries/faust/highlights.scm
+++ b/queries/faust/highlights.scm
@@ -1,11 +1,17 @@
; Identifiers
(identifier) @variable
-(process) @variable.builtin
+[
+ "process"
+ "effect"
+] @variable.builtin
(parameters
(identifier)) @variable.parameter
+(access
+ definition: (identifier) @variable.member)
+
(global_metadata
key: (identifier) @variable.member)
@@ -49,16 +55,12 @@
(function_names) @function
-[
- (lambda)
- (prefix)
- (prim1)
- (prim2)
- (prim3)
- (prim4)
- (prim5)
- (function_call)
-] @function.call
+(function_call
+ (identifier) @function.call)
+
+(function_call
+ (access
+ definition: (identifier) @function.call))
[
"exp"