diff rust/hg-core/src/dirstate/entry.rs @ 48064:2943955304b3

dirstate: inline the merged_removed logic It is used internally for compatibilty with size used in the `v1` format, but this is the only use. So we can simply inline it. Differential Revision: https://phab.mercurial-scm.org/D11512
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Tue, 28 Sep 2021 19:12:44 +0200
parents 060cd909439f
children 870100c0209b
line wrap: on
line diff
--- a/rust/hg-core/src/dirstate/entry.rs	Tue Sep 28 18:57:20 2021 +0200
+++ b/rust/hg-core/src/dirstate/entry.rs	Tue Sep 28 19:12:44 2021 +0200
@@ -216,7 +216,7 @@
     }
 
     pub fn size(&self) -> i32 {
-        if self.merged_removed() {
+        if self.removed() && self.flags.contains(Flags::MERGED) {
             SIZE_NON_NORMAL
         } else if self.from_p2_removed() {
             SIZE_FROM_OTHER_PARENT