Highlight punctuation as HighlightTag::Operator

This commit is contained in:
Leander Tentrup
2020-07-13 22:59:42 +02:00
parent 57652fc9d4
commit 33832d43fc
7 changed files with 188 additions and 187 deletions

View File

@@ -553,6 +553,7 @@ fn highlight_element(
T![!] if element.parent().and_then(ast::MacroCall::cast).is_some() => {
Highlight::new(HighlightTag::Macro)
}
p if p.is_punct() => HighlightTag::Operator.into(),
k if k.is_keyword() => {
let h = Highlight::new(HighlightTag::Keyword);