diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-09-06 12:23:31 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2019-09-06 12:23:31 +0100 |
commit | 2015e8b4d15c8be6c8fd735b0c08ccbbe24fb934 (patch) | |
tree | 5f5adc8ffd4c29d104e646057f636def67ac2549 /crates/ra_ide_api/src/change.rs | |
parent | 3bdb456d17660f3460bbf2c38315568b2f76aaa5 (diff) | |
parent | 9ae455ea52bf0bc60476fdb3d50d05f5873040c1 (diff) |
Merge #1778
1778: make source_root API more abstract r=matklad a=matklad
bors r+
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_ide_api/src/change.rs')
-rw-r--r-- | crates/ra_ide_api/src/change.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/change.rs b/crates/ra_ide_api/src/change.rs index 0234c572d..89631935a 100644 --- a/crates/ra_ide_api/src/change.rs +++ b/crates/ra_ide_api/src/change.rs | |||
@@ -213,11 +213,11 @@ impl RootDatabase { | |||
213 | durability, | 213 | durability, |
214 | ); | 214 | ); |
215 | self.set_file_source_root_with_durability(add_file.file_id, root_id, durability); | 215 | self.set_file_source_root_with_durability(add_file.file_id, root_id, durability); |
216 | source_root.files.insert(add_file.path, add_file.file_id); | 216 | source_root.insert_file(add_file.path, add_file.file_id); |
217 | } | 217 | } |
218 | for remove_file in root_change.removed { | 218 | for remove_file in root_change.removed { |
219 | self.set_file_text_with_durability(remove_file.file_id, Default::default(), durability); | 219 | self.set_file_text_with_durability(remove_file.file_id, Default::default(), durability); |
220 | source_root.files.remove(&remove_file.path); | 220 | source_root.remove_file(&remove_file.path); |
221 | } | 221 | } |
222 | self.set_source_root_with_durability(root_id, Arc::new(source_root), durability); | 222 | self.set_source_root_with_durability(root_id, Arc::new(source_root), durability); |
223 | } | 223 | } |