mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-13 13:48:50 +00:00
Color lifetimes like types
This commit is contained in:
parent
a91d15c80c
commit
d5d154ba3f
1 changed files with 4 additions and 12 deletions
|
@ -586,23 +586,15 @@
|
||||||
},
|
},
|
||||||
"lifetime": {
|
"lifetime": {
|
||||||
"comment": "Named lifetime",
|
"comment": "Named lifetime",
|
||||||
"name": "storage.modifier.lifetime.rust",
|
"name": "entity.name.type.lifetime.rust",
|
||||||
"match": "'([a-zA-Z_][a-zA-Z0-9_]*)\\b",
|
"match": "'([a-zA-Z_][a-zA-Z0-9_]*)\\b"
|
||||||
"captures": {
|
|
||||||
"1": {
|
|
||||||
"name": "entity.name.lifetime.rust"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"ref_lifetime": {
|
"ref_lifetime": {
|
||||||
"comment": "Reference with named lifetime",
|
"comment": "Reference with named lifetime",
|
||||||
"match": "&('([a-zA-Z_][a-zA-Z0-9_]*))\\b",
|
"match": "&('[a-zA-Z_][a-zA-Z0-9_]*)\\b",
|
||||||
"captures": {
|
"captures": {
|
||||||
"1": {
|
"1": {
|
||||||
"name": "storage.modifier.lifetime.rust"
|
"name": "entity.name.type.lifetime.rust"
|
||||||
},
|
|
||||||
"2": {
|
|
||||||
"name": "entity.name.lifetime.rust"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue