aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_api/src/syntax_highlighting.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide_api/src/syntax_highlighting.rs')
-rw-r--r--crates/ra_ide_api/src/syntax_highlighting.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/syntax_highlighting.rs b/crates/ra_ide_api/src/syntax_highlighting.rs
index 739b898d2..bf4e9c9d1 100644
--- a/crates/ra_ide_api/src/syntax_highlighting.rs
+++ b/crates/ra_ide_api/src/syntax_highlighting.rs
@@ -32,7 +32,7 @@ fn is_control_keyword(kind: SyntaxKind) -> bool {
32 32
33pub(crate) fn highlight(db: &RootDatabase, file_id: FileId) -> Vec<HighlightedRange> { 33pub(crate) fn highlight(db: &RootDatabase, file_id: FileId) -> Vec<HighlightedRange> {
34 let _p = profile("highlight"); 34 let _p = profile("highlight");
35 let source_file = db.parse(file_id); 35 let source_file = db.parse(file_id).tree;
36 36
37 fn calc_binding_hash(file_id: FileId, text: &SmolStr, shadow_count: u32) -> u64 { 37 fn calc_binding_hash(file_id: FileId, text: &SmolStr, shadow_count: u32) -> u64 {
38 fn hash<T: std::hash::Hash + std::fmt::Debug>(x: T) -> u64 { 38 fn hash<T: std::hash::Hash + std::fmt::Debug>(x: T) -> u64 {
@@ -177,7 +177,7 @@ pub(crate) fn highlight(db: &RootDatabase, file_id: FileId) -> Vec<HighlightedRa
177} 177}
178 178
179pub(crate) fn highlight_as_html(db: &RootDatabase, file_id: FileId, rainbow: bool) -> String { 179pub(crate) fn highlight_as_html(db: &RootDatabase, file_id: FileId, rainbow: bool) -> String {
180 let source_file = db.parse(file_id); 180 let source_file = db.parse(file_id).tree;
181 181
182 fn rainbowify(seed: u64) -> String { 182 fn rainbowify(seed: u64) -> String {
183 use rand::prelude::*; 183 use rand::prelude::*;