diff options
author | Aleksey Kladov <[email protected]> | 2021-01-09 11:44:01 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2021-01-09 11:44:01 +0000 |
commit | 64a6ee45351a71cdeb1d1dddc8fc746abdcff07b (patch) | |
tree | 1bcbd575286076950bf71719f8944e2d4322f939 /crates/ide/src/syntax_highlighting/injection.rs | |
parent | 6fb52af521ab8ca2fdd3ea7cfa95eaebd0cba1fc (diff) |
Shorten frequent names
Diffstat (limited to 'crates/ide/src/syntax_highlighting/injection.rs')
-rw-r--r-- | crates/ide/src/syntax_highlighting/injection.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/ide/src/syntax_highlighting/injection.rs b/crates/ide/src/syntax_highlighting/injection.rs index 98ee03e0d..a6941234e 100644 --- a/crates/ide/src/syntax_highlighting/injection.rs +++ b/crates/ide/src/syntax_highlighting/injection.rs | |||
@@ -7,7 +7,7 @@ use ide_db::call_info::ActiveParameter; | |||
7 | use itertools::Itertools; | 7 | use itertools::Itertools; |
8 | use syntax::{ast, AstToken, SyntaxNode, SyntaxToken, TextRange, TextSize}; | 8 | use syntax::{ast, AstToken, SyntaxNode, SyntaxToken, TextRange, TextSize}; |
9 | 9 | ||
10 | use crate::{Analysis, HighlightModifier, HighlightTag, HighlightedRange, RootDatabase}; | 10 | use crate::{Analysis, HighlightedRange, HlMod, HlTag, RootDatabase}; |
11 | 11 | ||
12 | use super::{highlights::Highlights, injector::Injector}; | 12 | use super::{highlights::Highlights, injector::Injector}; |
13 | 13 | ||
@@ -28,7 +28,7 @@ pub(super) fn highlight_injection( | |||
28 | if let Some(range) = literal.open_quote_text_range() { | 28 | if let Some(range) = literal.open_quote_text_range() { |
29 | acc.add(HighlightedRange { | 29 | acc.add(HighlightedRange { |
30 | range, | 30 | range, |
31 | highlight: HighlightTag::StringLiteral.into(), | 31 | highlight: HlTag::StringLiteral.into(), |
32 | binding_hash: None, | 32 | binding_hash: None, |
33 | }) | 33 | }) |
34 | } | 34 | } |
@@ -44,7 +44,7 @@ pub(super) fn highlight_injection( | |||
44 | if let Some(range) = literal.close_quote_text_range() { | 44 | if let Some(range) = literal.close_quote_text_range() { |
45 | acc.add(HighlightedRange { | 45 | acc.add(HighlightedRange { |
46 | range, | 46 | range, |
47 | highlight: HighlightTag::StringLiteral.into(), | 47 | highlight: HlTag::StringLiteral.into(), |
48 | binding_hash: None, | 48 | binding_hash: None, |
49 | }) | 49 | }) |
50 | } | 50 | } |
@@ -171,7 +171,7 @@ pub(super) fn extract_doc_comments(node: &SyntaxNode) -> Option<(Vec<Highlighted | |||
171 | range.start(), | 171 | range.start(), |
172 | range.start() + TextSize::try_from(pos).unwrap(), | 172 | range.start() + TextSize::try_from(pos).unwrap(), |
173 | ), | 173 | ), |
174 | highlight: HighlightTag::Comment | HighlightModifier::Documentation, | 174 | highlight: HlTag::Comment | HlMod::Documentation, |
175 | binding_hash: None, | 175 | binding_hash: None, |
176 | }); | 176 | }); |
177 | line_start += range.len() - TextSize::try_from(pos).unwrap(); | 177 | line_start += range.len() - TextSize::try_from(pos).unwrap(); |
@@ -209,7 +209,7 @@ pub(super) fn highlight_doc_comment( | |||
209 | for r in inj.map_range_up(h.range) { | 209 | for r in inj.map_range_up(h.range) { |
210 | stack.add(HighlightedRange { | 210 | stack.add(HighlightedRange { |
211 | range: r, | 211 | range: r, |
212 | highlight: h.highlight | HighlightModifier::Injected, | 212 | highlight: h.highlight | HlMod::Injected, |
213 | binding_hash: h.binding_hash, | 213 | binding_hash: h.binding_hash, |
214 | }); | 214 | }); |
215 | } | 215 | } |