Patchwork D10991: dirstate-item: use the properties in `contrib/dirstatenonnormalcheck.py`

login
register
mail settings
Submitter phabricator
Date July 5, 2021, 9:35 a.m.
Message ID <differential-rev-PHID-DREV-wugnaxo3l2pl3wb7ggyw-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/49302/
State Superseded
Headers show

Comments

phabricator - July 5, 2021, 9:35 a.m.
marmoute created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  contrib/dirstatenonnormalcheck.py

CHANGE DETAILS




To: marmoute, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/contrib/dirstatenonnormalcheck.py b/contrib/dirstatenonnormalcheck.py
--- a/contrib/dirstatenonnormalcheck.py
+++ b/contrib/dirstatenonnormalcheck.py
@@ -18,7 +18,7 @@ 
     """Compute nonnormal entries from dirstate's dmap"""
     res = set()
     for f, e in dmap.iteritems():
-        if e[0] != b'n' or e[3] == -1:
+        if e.state != b'n' or e.mtime == -1:
             res.add(f)
     return res