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
--- 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):