summaryrefslogtreecommitdiff
path: root/runtime/queries/llvm/textobjects.scm
diff options
context:
space:
mode:
authorSebastian Neubauer2021-12-29 09:30:44 +0000
committerGitHub2021-12-29 09:30:44 +0000
commit8c29b76bccc51c19c90f7c9ee156fe2cb6f52e2c (patch)
tree66a5e67fb34c18dadc5405241e450603b44c3fb2 /runtime/queries/llvm/textobjects.scm
parentf1ed042c84fedebc1eff91d00c9c58477e912edc (diff)
Improve llvm highlighting and queries (#1388)
* Improve llvm highlighting and queries The llvm tree-sitter parser was updated to support scopes and more accurate highlighting. * Group highlight expressions better
Diffstat (limited to 'runtime/queries/llvm/textobjects.scm')
-rw-r--r--runtime/queries/llvm/textobjects.scm16
1 files changed, 16 insertions, 0 deletions
diff --git a/runtime/queries/llvm/textobjects.scm b/runtime/queries/llvm/textobjects.scm
new file mode 100644
index 00000000..3738a3bb
--- /dev/null
+++ b/runtime/queries/llvm/textobjects.scm
@@ -0,0 +1,16 @@
+(define
+ body: (_) @function.inside) @function.around
+
+(struct_type
+ (struct_body) @class.inside) @class.around
+
+(packed_struct_type
+ (struct_body) @class.inside) @class.around
+
+(array_type
+ (array_vector_body) @class.inside) @class.around
+
+(vector_type
+ (array_vector_body) @class.inside) @class.around
+
+(argument) @parameter.inside