feat(t32)!: update parser and queries (#8276)

`trace32_hll_variable` has been removed from the grammar. The
queries are now capturing `symbol` instead. `symbol` is highlighted
as variable or constant.
This commit is contained in:
Christoph Sax 2025-11-12 10:06:04 +01:00 committed by GitHub
parent f46e3a09bd
commit b50774079a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 17 additions and 13 deletions

View file

@ -102,8 +102,6 @@
(path) @string.special.path
(symbol) @string.special.symbol
[
(character)
(hll_char_literal)
@ -159,7 +157,7 @@
; Variables, constants and labels
(macro) @variable.builtin
(trace32_hll_variable) @variable.builtin
(symbol) @variable
(argument_list
(identifier) @constant.builtin)
@ -168,6 +166,12 @@
(identifier) @constant.builtin)
(#lua-match? @constant.builtin "^[%%/][%l%u][%l%u%d.]*$"))
((symbol) @constant
(#lua-match? @constant "^\\\\\\\\\\\\[^\\\\]*(\\\\\\\\[^\\\\]*)?(\\\\[^\\\\]*)?$"))
((symbol) @constant
(#lua-match? @constant "^\\\\\\\\[^\\\\]*(\\\\[^\\\\]*)?$"))
((command_expression
command: (identifier) @keyword
arguments: (argument_list

View file

@ -13,7 +13,7 @@
(command_expression
command: (identifier)
arguments: (argument_list
declarator: (trace32_hll_variable) @local.definition.var))
declarator: (symbol) @local.definition.var))
; Function definitions
(subroutine_block
@ -32,5 +32,5 @@
[
(macro)
(trace32_hll_variable)
(symbol)
] @local.reference