changeset 19174:022256ef47b8

dirstate._walkexplicit: rename work to dirsfound Now that this code is factored out, work is too specific a name.
author Siddharth Agarwal <sid0@fb.com>
date Tue, 07 May 2013 14:19:04 -0700
parents ec70a78a70e0
children 63f7bd2e1a46
files mercurial/dirstate.py
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/dirstate.py	Tue May 07 10:02:55 2013 -0700
+++ b/mercurial/dirstate.py	Tue May 07 14:19:04 2013 -0700
@@ -525,10 +525,10 @@
     def _walkexplicit(self, match, subrepos):
         '''Get stat data about the files explicitly specified by match.
 
-        Return a triple (results, work, dirsnotfound).
+        Return a triple (results, dirsfound, dirsnotfound).
         - results is a mapping from filename to stat result. It also contains
           listings mapping subrepos and .hg to None.
-        - work is a list of files found to be directories.
+        - dirsfound is a list of files found to be directories.
         - dirsnotfound is a list of files that the dirstate thinks are
           directories and that were not found.'''
 
@@ -556,8 +556,8 @@
         regkind = stat.S_IFREG
         lnkkind = stat.S_IFLNK
         join = self._join
-        work = []
-        wadd = work.append
+        dirsfound = []
+        foundadd = dirsfound.append
         dirsnotfound = []
 
         if match.matchfn != match.exact and self._checkcase:
@@ -599,7 +599,7 @@
                         results[nf] = None
                     if matchedir:
                         matchedir(nf)
-                    wadd(nf)
+                    foundadd(nf)
                 elif kind == regkind or kind == lnkkind:
                     results[nf] = st
                 else:
@@ -620,7 +620,7 @@
                     else:
                         badfn(ff, inst.strerror)
 
-        return results, work, dirsnotfound
+        return results, dirsfound, dirsnotfound
 
     def walk(self, match, subrepos, unknown, ignored):
         '''