mercurial/dirstatemap.py
changeset 47685 265cdfaad372
parent 47683 284a20269a97
child 47686 e43128ee436f
--- a/mercurial/dirstatemap.py	Fri Jul 16 16:19:31 2021 +0200
+++ b/mercurial/dirstatemap.py	Wed Jul 14 21:59:18 2021 +0200
@@ -196,8 +196,8 @@
             self._dirs.addpath(f)
         if old_entry is None and "_alldirs" in self.__dict__:
             self._alldirs.addpath(f)
-        self._map[f] = DirstateItem(state, mode, size, mtime)
-        if state != b'n' or mtime == AMBIGUOUS_TIME:
+        e = self._map[f] = DirstateItem(state, mode, size, mtime)
+        if e.dm_nonnormal:
             self.nonnormalset.add(f)
         if size == FROM_P2:
             self.otherparentset.add(f)
@@ -274,7 +274,7 @@
             nonnorm = set()
             otherparent = set()
             for fname, e in pycompat.iteritems(self._map):
-                if e.state != b'n' or e.mtime == AMBIGUOUS_TIME:
+                if e.dm_nonnormal:
                     nonnorm.add(fname)
                 if e.from_p2:
                     otherparent.add(fname)