changeset 47935:97e9f3fd9324

dirstate-item: add more logic to `from_p2` This seem semantically better even if this tracking case seems to always comes with clean_p2 for now. Differential Revision: https://phab.mercurial-scm.org/D11372
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Fri, 27 Aug 2021 18:04:49 +0200
parents f94cc63df859
children 0d185f73c619
files mercurial/pure/parsers.py
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/pure/parsers.py	Fri Aug 27 17:14:54 2021 +0200
+++ b/mercurial/pure/parsers.py	Fri Aug 27 18:04:49 2021 +0200
@@ -286,7 +286,9 @@
 
         Should only be set if a merge is in progress in the dirstate
         """
-        return self._wc_tracked and self._clean_p2
+        if not self._wc_tracked:
+            return False
+        return self._clean_p2 or (not self._p1_tracked and self._p2_tracked)
 
     @property
     def from_p2_removed(self):