aboutsummaryrefslogtreecommitdiffstats
path: root/queries/thrift/highlights.scm
diff options
context:
space:
mode:
authorAmaan Qureshi <amaanq12@gmail.com>2023-01-23 08:37:15 -0500
committerStephan Seitz <stephan.seitz@fau.de>2023-01-23 22:26:16 +0100
commitf826b7af1307737afa546cf67a0715a5e54ad99b (patch)
tree7f84ebd4e43b887d705c94b625d69963c4f2b791 /queries/thrift/highlights.scm
parentfix: detach behaviour on buffer reload (diff)
downloadnvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar.gz
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar.bz2
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar.lz
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar.xz
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.tar.zst
nvim-treesitter-f826b7af1307737afa546cf67a0715a5e54ad99b.zip
refactor(capnp, thrift): improve grammar & queries to stable for the foreseeable future
Diffstat (limited to 'queries/thrift/highlights.scm')
-rw-r--r--queries/thrift/highlights.scm12
1 files changed, 8 insertions, 4 deletions
diff --git a/queries/thrift/highlights.scm b/queries/thrift/highlights.scm
index d06fbe03f..f5d8a7ef3 100644
--- a/queries/thrift/highlights.scm
+++ b/queries/thrift/highlights.scm
@@ -1,6 +1,6 @@
; Namespace
-(namespace) @namespace
+(namespace_definition) @namespace
; Includes
@@ -47,14 +47,17 @@
; Types
(enum_identifier) @type
+(definition_type) @type
(exception_identifier) @type
(exception_param_type) @type
(field_type) @type
+(param_type) @type
(type_identifier) @type
; Attributes
(annotation_identifier) @attribute
+(uri_def) @attribute
; Operators
@@ -62,7 +65,6 @@
"="
"+"
"-"
- "&"
] @operator
; Exceptions
@@ -113,12 +115,13 @@
"xsd_optional"
] @keyword
-(namespace_scope) @namespace
; Literals
(string_literal) @string
+(uri) @string.special
+
(number) @number
(double) @float
@@ -127,7 +130,7 @@
; Typedefs
(typedef_definition) @type.definition
-(namespace_definition) @type.definition
+(namespace_scope) @type.definition
; Misc
@@ -137,6 +140,7 @@
[
"*"
+ "&"
] @punctuation.special
(field_modifier) @attribute