mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 21:35:20 +00:00
Shorten frequent names
This commit is contained in:
parent
6fb52af521
commit
64a6ee4535
8 changed files with 222 additions and 246 deletions
|
@ -4,7 +4,7 @@ use syntax::{
|
|||
AstNode, AstToken, SyntaxElement, SyntaxKind, SyntaxNode, TextRange,
|
||||
};
|
||||
|
||||
use crate::{HighlightTag, HighlightedRange, SymbolKind};
|
||||
use crate::{HighlightedRange, HlTag, SymbolKind};
|
||||
|
||||
use super::highlights::Highlights;
|
||||
|
||||
|
@ -57,7 +57,7 @@ impl FormatStringHighlighter {
|
|||
}
|
||||
}
|
||||
|
||||
fn highlight_format_specifier(kind: FormatSpecifier) -> Option<HighlightTag> {
|
||||
fn highlight_format_specifier(kind: FormatSpecifier) -> Option<HlTag> {
|
||||
Some(match kind {
|
||||
FormatSpecifier::Open
|
||||
| FormatSpecifier::Close
|
||||
|
@ -69,8 +69,8 @@ fn highlight_format_specifier(kind: FormatSpecifier) -> Option<HighlightTag> {
|
|||
| FormatSpecifier::DollarSign
|
||||
| FormatSpecifier::Dot
|
||||
| FormatSpecifier::Asterisk
|
||||
| FormatSpecifier::QuestionMark => HighlightTag::FormatSpecifier,
|
||||
FormatSpecifier::Integer | FormatSpecifier::Zero => HighlightTag::NumericLiteral,
|
||||
FormatSpecifier::Identifier => HighlightTag::Symbol(SymbolKind::Local),
|
||||
| FormatSpecifier::QuestionMark => HlTag::FormatSpecifier,
|
||||
FormatSpecifier::Integer | FormatSpecifier::Zero => HlTag::NumericLiteral,
|
||||
FormatSpecifier::Identifier => HlTag::Symbol(SymbolKind::Local),
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue