mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-17 19:00:02 -04:00
feat(thrift): use better queries, namely for idents (#4197)
This commit is contained in:
parent
8448261061
commit
b300d903b0
3 changed files with 23 additions and 5 deletions
|
|
@ -27,16 +27,31 @@
|
|||
|
||||
; Fields
|
||||
|
||||
(field) @field
|
||||
(field_identifier) @field
|
||||
|
||||
; Parameters
|
||||
|
||||
(parameter) @parameter
|
||||
(param_identifier) @parameter
|
||||
|
||||
; Variables
|
||||
|
||||
(identifier) @variable
|
||||
|
||||
; Constants
|
||||
|
||||
(const_identifier) @constant
|
||||
(enum_member) @constant
|
||||
|
||||
; Types
|
||||
|
||||
(enum_identifier) @type
|
||||
(field_type) @type
|
||||
(type_identifier) @type
|
||||
|
||||
; Attributes
|
||||
|
||||
(annotation_identifier) @attribute
|
||||
|
||||
; Operators
|
||||
|
||||
[
|
||||
|
|
@ -75,7 +90,8 @@
|
|||
"void"
|
||||
] @keyword
|
||||
|
||||
; Deprecated
|
||||
; Deprecated Keywords
|
||||
|
||||
[
|
||||
"async"
|
||||
"byte"
|
||||
|
|
@ -110,6 +126,7 @@
|
|||
(boolean) @boolean
|
||||
|
||||
(typedef_definition) @type.definition
|
||||
(namespace_definition) @type.definition
|
||||
|
||||
[
|
||||
"const"
|
||||
|
|
@ -129,6 +146,8 @@
|
|||
|
||||
["[" "]"] @punctuation.bracket
|
||||
|
||||
["<" ">"] @punctuation.bracket
|
||||
|
||||
[
|
||||
";"
|
||||
","
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue