From 33832d43fcc10fd6da0edf004d575f3576d9e91d Mon Sep 17 00:00:00 2001 From: Leander Tentrup Date: Mon, 13 Jul 2020 22:59:42 +0200 Subject: Highlight punctuation as `HighlightTag::Operator` --- crates/ra_ide/src/syntax_highlighting.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'crates/ra_ide/src/syntax_highlighting.rs') diff --git a/crates/ra_ide/src/syntax_highlighting.rs b/crates/ra_ide/src/syntax_highlighting.rs index b3236e821..6067207d9 100644 --- a/crates/ra_ide/src/syntax_highlighting.rs +++ b/crates/ra_ide/src/syntax_highlighting.rs @@ -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); -- cgit v1.2.3