aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_api/src/line_index_utils.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide_api/src/line_index_utils.rs')
-rw-r--r--crates/ra_ide_api/src/line_index_utils.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/crates/ra_ide_api/src/line_index_utils.rs b/crates/ra_ide_api/src/line_index_utils.rs
index f9073dca2..8f63db5f1 100644
--- a/crates/ra_ide_api/src/line_index_utils.rs
+++ b/crates/ra_ide_api/src/line_index_utils.rs
@@ -137,7 +137,7 @@ impl<'a> Edits<'a> {
137 Step::Newline(n) => n, 137 Step::Newline(n) => n,
138 Step::Utf16Char(r) => r.end(), 138 Step::Utf16Char(r) => r.end(),
139 }; 139 };
140 let res = match &mut self.current { 140 match &mut self.current {
141 Some(edit) => { 141 Some(edit) => {
142 if step_pos <= edit.delete.start() { 142 if step_pos <= edit.delete.start() {
143 NextSteps::Use 143 NextSteps::Use
@@ -155,8 +155,7 @@ impl<'a> Edits<'a> {
155 } 155 }
156 } 156 }
157 None => NextSteps::Use, 157 None => NextSteps::Use,
158 }; 158 }
159 res
160 } 159 }
161 160
162 fn translate_range(&self, range: TextRange) -> TextRange { 161 fn translate_range(&self, range: TextRange) -> TextRange {