aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide/src/references
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide/src/references')
-rw-r--r--crates/ra_ide/src/references/rename.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_ide/src/references/rename.rs b/crates/ra_ide/src/references/rename.rs
index a8f320e2f..fd17bc9f2 100644
--- a/crates/ra_ide/src/references/rename.rs
+++ b/crates/ra_ide/src/references/rename.rs
@@ -51,12 +51,12 @@ fn source_edit_from_reference(reference: Reference, new_name: &str) -> SourceFil
51 let mut replacement_text = String::new(); 51 let mut replacement_text = String::new();
52 let file_id = reference.file_range.file_id; 52 let file_id = reference.file_range.file_id;
53 let range = match reference.kind { 53 let range = match reference.kind {
54 ReferenceKind::StructFieldShorthandForField => { 54 ReferenceKind::FieldShorthandForField => {
55 replacement_text.push_str(new_name); 55 replacement_text.push_str(new_name);
56 replacement_text.push_str(": "); 56 replacement_text.push_str(": ");
57 TextRange::new(reference.file_range.range.start(), reference.file_range.range.start()) 57 TextRange::new(reference.file_range.range.start(), reference.file_range.range.start())
58 } 58 }
59 ReferenceKind::StructFieldShorthandForLocal => { 59 ReferenceKind::FieldShorthandForLocal => {
60 replacement_text.push_str(": "); 60 replacement_text.push_str(": ");
61 replacement_text.push_str(new_name); 61 replacement_text.push_str(new_name);
62 TextRange::new(reference.file_range.range.end(), reference.file_range.range.end()) 62 TextRange::new(reference.file_range.range.end(), reference.file_range.range.end())