Patchwork D11531: dirstate-item: use `tracked` instead of the `state` in context's iter

login
register
mail settings
Submitter phabricator
Date Oct. 1, 2021, 9:42 a.m.
Message ID <differential-rev-PHID-DREV-3yhltmuhmaqovn2ukfou-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/49857/
State Superseded
Headers show

Comments

phabricator - Oct. 1, 2021, 9:42 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/D11531

AFFECTED FILES
  mercurial/context.py

CHANGE DETAILS




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

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -1551,7 +1551,7 @@ 
     def __iter__(self):
         d = self._repo.dirstate
         for f in d:
-            if d[f] != b'r':
+            if d.get_entry(f).tracked:
                 yield f
 
     def __contains__(self, key):