aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_db
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide_db')
-rw-r--r--crates/ra_ide_db/src/source_change.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/crates/ra_ide_db/src/source_change.rs b/crates/ra_ide_db/src/source_change.rs
index af81a91a4..c64165f3a 100644
--- a/crates/ra_ide_db/src/source_change.rs
+++ b/crates/ra_ide_db/src/source_change.rs
@@ -13,6 +13,7 @@ pub struct SourceChange {
13 pub source_file_edits: Vec<SourceFileEdit>, 13 pub source_file_edits: Vec<SourceFileEdit>,
14 pub file_system_edits: Vec<FileSystemEdit>, 14 pub file_system_edits: Vec<FileSystemEdit>,
15 pub cursor_position: Option<FilePosition>, 15 pub cursor_position: Option<FilePosition>,
16 pub is_snippet: bool,
16} 17}
17 18
18impl SourceChange { 19impl SourceChange {
@@ -28,6 +29,7 @@ impl SourceChange {
28 source_file_edits, 29 source_file_edits,
29 file_system_edits, 30 file_system_edits,
30 cursor_position: None, 31 cursor_position: None,
32 is_snippet: false,
31 } 33 }
32 } 34 }
33 35
@@ -41,6 +43,7 @@ impl SourceChange {
41 source_file_edits: edits, 43 source_file_edits: edits,
42 file_system_edits: vec![], 44 file_system_edits: vec![],
43 cursor_position: None, 45 cursor_position: None,
46 is_snippet: false,
44 } 47 }
45 } 48 }
46 49
@@ -52,6 +55,7 @@ impl SourceChange {
52 source_file_edits: vec![], 55 source_file_edits: vec![],
53 file_system_edits: edits, 56 file_system_edits: edits,
54 cursor_position: None, 57 cursor_position: None,
58 is_snippet: false,
55 } 59 }
56 } 60 }
57 61
@@ -115,6 +119,7 @@ impl SingleFileChange {
115 source_file_edits: vec![SourceFileEdit { file_id, edit: self.edit }], 119 source_file_edits: vec![SourceFileEdit { file_id, edit: self.edit }],
116 file_system_edits: Vec::new(), 120 file_system_edits: Vec::new(),
117 cursor_position: self.cursor_position.map(|offset| FilePosition { file_id, offset }), 121 cursor_position: self.cursor_position.map(|offset| FilePosition { file_id, offset }),
122 is_snippet: false,
118 } 123 }
119 } 124 }
120} 125}