fix(odin): updates queries from upstream (#6425)

This commit is contained in:
Laytan 2024-04-10 12:46:25 +02:00 committed by GitHub
parent 8253aac419
commit 2bad828b48
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 37 additions and 9 deletions

View file

@ -24,6 +24,7 @@
"map"
"bit_set"
"matrix"
"bit_field"
] @keyword
"proc" @keyword.function
@ -151,6 +152,10 @@
(identifier) @type
"::")
(bit_field_declaration
(identifier) @type
"::")
(const_declaration
(identifier) @type
"::"

View file

@ -1,24 +1,43 @@
[
(block)
(procedure_declaration)
(overloaded_procedure_declaration)
(enum_declaration)
(union_declaration)
(if_statement)
(else_if_clause)
(else_clause)
(when_statement)
(else_when_clause)
(for_statement)
(bit_field_declaration)
(struct_declaration)
(struct)
(parameters)
(tuple_type)
(call_expression)
(switch_case)
] @indent.begin
; hello(
((identifier)
.
(ERROR
"(" @indent.begin))
[
"}"
")"
"]"
] @indent.branch @indent.end
; Have to do all closing brackets separately because the one for switch statements shouldn't end.
(block
"}" @indent.branch @indent.end)
(enum_declaration
"}" @indent.branch @indent.end)
(union_declaration
"}" @indent.branch @indent.end)
(struct_declaration
"}" @indent.branch @indent.end)
(struct
"}" @indent.branch @indent.end)
[
(comment)
(block_comment)

View file

@ -30,6 +30,10 @@
(identifier) @local.definition.type
"::")
(bit_field_declaration
(identifier) @local.definition.type
"::")
(variable_declaration
(identifier) @local.definition.var
":=")