diff -r 33beeb32f73a -r e5fb14a07866 rust/hg-core/src/dirstate_tree/dirstate_map.rs --- a/rust/hg-core/src/dirstate_tree/dirstate_map.rs Fri Jul 16 22:30:11 2021 +0200 +++ b/rust/hg-core/src/dirstate_tree/dirstate_map.rs Mon Jul 19 07:23:55 2021 +0200 @@ -757,6 +757,16 @@ self.nodes_with_copy_source_count = 0; } + fn set_v1(&mut self, filename: &HgPath, entry: DirstateEntry) { + let node = + self.get_or_insert(&filename).expect("no parse error in v1"); + node.data = NodeData::Entry(entry); + node.children = ChildNodes::default(); + node.copy_source = None; + node.descendants_with_entry_count = 0; + node.tracked_descendants_count = 0; + } + fn add_file( &mut self, filename: &HgPath, @@ -982,7 +992,16 @@ }) } - fn non_normal_entries_remove(&mut self, _key: &HgPath) { + fn non_normal_entries_remove(&mut self, key: &HgPath) -> bool { + // Do nothing, this `DirstateMap` does not have a separate "non normal + // entries" set that need to be kept up to date. + if let Ok(Some(v)) = self.get(key) { + return v.is_non_normal(); + } + false + } + + fn non_normal_entries_add(&mut self, _key: &HgPath) { // Do nothing, this `DirstateMap` does not have a separate "non normal // entries" set that need to be kept up to date }