[Updated] D10977: dirstate: drop the last explicit `state` usage in the module

marmoute (Pierre-Yves David) phabricator at mercurial-scm.org
Thu Jul 8 16:06:36 UTC 2021


Closed by commit rHG811a79bfb8bb: dirstate: drop the last explicit `state` usage in the module (authored by marmoute).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D10977?vs=29008&id=29016

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D10977/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D10977

AFFECTED FILES
  mercurial/dirstate.py

CHANGE DETAILS

diff --git a/mercurial/dirstate.py b/mercurial/dirstate.py
--- a/mercurial/dirstate.py
+++ b/mercurial/dirstate.py
@@ -536,7 +536,8 @@
         if not self.in_merge:
             msg = _(b"setting %r to other parent only allowed in merges") % f
             raise error.Abort(msg)
-        if f in self and self[f] == b'n':
+        entry = self._map.get(f)
+        if entry is not None and entry.tracked:
             # merge-like
             self._addpath(f, merged=True)
         else:



To: marmoute, #hg-reviewers, Alphare
Cc: Alphare, SimonSapin, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210708/2a027a04/attachment-0002.html>


More information about the Mercurial-patches mailing list