Fix pattern order in C++ highlight query
Later patterns take precedence in Zed, so function names were previously being highlighted as variables due to the plain `identifier` pattern.
This commit is contained in:
parent
f96c19b81a
commit
d48380bc48
1 changed files with 2 additions and 2 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
(identifier) @variable
|
||||||
|
|
||||||
(call_expression
|
(call_expression
|
||||||
function: (qualified_identifier
|
function: (qualified_identifier
|
||||||
name: (identifier) @function))
|
name: (identifier) @function))
|
||||||
|
@ -34,8 +36,6 @@
|
||||||
(auto) @type
|
(auto) @type
|
||||||
(type_identifier) @type
|
(type_identifier) @type
|
||||||
|
|
||||||
(identifier) @variable
|
|
||||||
|
|
||||||
((identifier) @constant
|
((identifier) @constant
|
||||||
(#match? @constant "^[A-Z][A-Z\\d_]*$"))
|
(#match? @constant "^[A-Z][A-Z\\d_]*$"))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue