nvim-treesitter/runtime/queries/thrift/locals.scm

71 lines
1.1 KiB
Scheme
Raw Normal View History

; Scopes
2023-02-06 13:34:05 -05:00
[
(document)
(definition)
] @local.scope
; References
(identifier) @local.reference
; Definitions
(annotation_identifier) @local.definition
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(const_definition
(identifier) @local.definition.constant)
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(enum_definition
"enum"
.
(identifier) @local.definition.enum
"{"
(identifier) @local.definition.constant
"}")
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(senum_definition
"senum"
.
(identifier) @local.definition.enum)
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(field
(identifier) @local.definition.field)
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(function_definition
(identifier) @local.definition.function)
2023-02-06 13:34:05 -05:00
(namespace_declaration
2024-01-06 15:05:50 +09:00
"namespace"
(namespace_scope)
.
(_) @local.definition.namespace
(namespace_uri)?)
2023-02-06 13:34:05 -05:00
2024-01-06 15:05:50 +09:00
(parameter
(identifier) @local.definition.parameter)
(struct_definition
2024-01-06 15:05:50 +09:00
"struct"
.
(identifier) @local.definition.type)
(union_definition
2024-01-06 15:05:50 +09:00
"union"
.
(identifier) @local.definition.type)
(exception_definition
2024-01-06 15:05:50 +09:00
"exception"
.
(identifier) @local.definition.type)
(service_definition
2024-01-06 15:05:50 +09:00
"service"
.
(identifier) @local.definition.type)
(interaction_definition
2024-01-06 15:05:50 +09:00
"interaction"
.
(identifier) @local.definition.type)
(typedef_identifier) @local.definition.type