mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-13 08:50:11 -04:00
feat(rust): distinguish enum members better
This commit is contained in:
parent
74779349fc
commit
6df6dd2622
1 changed files with 12 additions and 0 deletions
|
|
@ -86,6 +86,18 @@
|
||||||
name: (identifier) @constant)
|
name: (identifier) @constant)
|
||||||
(#lua-match? @constant "^[A-Z][A-Z%d_]*$"))
|
(#lua-match? @constant "^[A-Z][A-Z%d_]*$"))
|
||||||
|
|
||||||
|
((scoped_identifier
|
||||||
|
path: (identifier) @type
|
||||||
|
name: (identifier) @constant)
|
||||||
|
(#lua-match? @type "^[A-Z]")
|
||||||
|
(#lua-match? @constant "^[A-Z]"))
|
||||||
|
|
||||||
|
((scoped_type_identifier
|
||||||
|
path: (identifier) @type
|
||||||
|
name: (type_identifier) @constant)
|
||||||
|
(#lua-match? @type "^[A-Z]")
|
||||||
|
(#lua-match? @constant "^[A-Z]"))
|
||||||
|
|
||||||
[
|
[
|
||||||
(crate)
|
(crate)
|
||||||
(super)
|
(super)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue