From 68706b59c9177db2a6dd276e1ce599d8fe5942c1 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Thu, 9 Jul 2020 19:21:41 +0200 Subject: Don't mess with cursor position when adding hashes --- crates/ra_ide/src/syntax_highlighting/injection.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'crates/ra_ide/src/syntax_highlighting') diff --git a/crates/ra_ide/src/syntax_highlighting/injection.rs b/crates/ra_ide/src/syntax_highlighting/injection.rs index 181c21256..8665b480f 100644 --- a/crates/ra_ide/src/syntax_highlighting/injection.rs +++ b/crates/ra_ide/src/syntax_highlighting/injection.rs @@ -25,7 +25,7 @@ pub(super) fn highlight_injection( return None; } let value = literal.value()?; - let (analysis, tmp_file_id) = Analysis::from_single_file(value); + let (analysis, tmp_file_id) = Analysis::from_single_file(value.into_owned()); if let Some(range) = literal.open_quote_text_range() { acc.add(HighlightedRange { -- cgit v1.2.3