subrepo: access status members by name instead of by position
authorMartin von Zweigbergk <martinvonz@google.com>
Wed, 17 Oct 2018 11:43:39 -0700
changeset 40342 6f152067ba57
parent 40341 d916ed3ca951
child 40343 a69d5823af6d
subrepo: access status members by name instead of by position Taking my first Mercurial project closer to completion. Differential Revision: https://phab.mercurial-scm.org/D5144
mercurial/subrepo.py
--- a/mercurial/subrepo.py	Tue Oct 16 07:21:00 2018 -0700
+++ b/mercurial/subrepo.py	Wed Oct 17 11:43:39 2018 -0700
@@ -1583,17 +1583,15 @@
         if self._gitmissing():
             return []
 
-        (modified, added, removed,
-         deleted, unknown, ignored, clean) = self.status(None, unknown=True,
-                                                         clean=True)
+        s = self.status(None, unknown=True, clean=True)
 
         tracked = set()
         # dirstates 'amn' warn, 'r' is added again
-        for l in (modified, added, deleted, clean):
+        for l in (s.modified, s.added, s.deleted, s.clean):
             tracked.update(l)
 
         # Unknown files not of interest will be rejected by the matcher
-        files = unknown
+        files = s.unknown
         files.extend(match.files())
 
         rejected = []