Mercurial > public > mercurial-scm > hg
diff rust/hg-core/src/dirstate_tree/dispatch.rs @ 48050:2ac0e6b23222
dirstate: Replace dropfile with drop_item_and_copy_source
Those removing a DirstateItem and a copy source are always done together
Differential Revision: https://phab.mercurial-scm.org/D11493
author | Simon Sapin <simon.sapin@octobus.net> |
---|---|
date | Thu, 23 Sep 2021 15:36:43 +0200 |
parents | 29aa633815db |
children | 98c0408324e6 |
line wrap: on
line diff
--- a/rust/hg-core/src/dirstate_tree/dispatch.rs Thu Sep 23 15:29:38 2021 +0200 +++ b/rust/hg-core/src/dirstate_tree/dispatch.rs Thu Sep 23 15:36:43 2021 +0200 @@ -66,7 +66,10 @@ /// Drop information about this file from the map if any. /// /// `get` will now return `None` for this filename. - fn drop_file(&mut self, filename: &HgPath) -> Result<(), DirstateError>; + fn drop_entry_and_copy_source( + &mut self, + filename: &HgPath, + ) -> Result<(), DirstateError>; /// Among given files, mark the stored `mtime` as ambiguous if there is one /// (if `state == EntryState::Normal`) equal to the given current Unix @@ -339,8 +342,11 @@ self.remove_file(filename, in_merge) } - fn drop_file(&mut self, filename: &HgPath) -> Result<(), DirstateError> { - self.drop_file(filename) + fn drop_entry_and_copy_source( + &mut self, + filename: &HgPath, + ) -> Result<(), DirstateError> { + self.drop_entry_and_copy_source(filename) } fn clear_ambiguous_times(