changeset 13325:7ebdfa37842e

subrepo: clarify comments in dirty() methods Just a little change to bring the comments in the dirty() methods of the various subrepo classes into a uniform structure. This clarifies the meaning of the states checked.
author Kevin Bullock <kbullock@ringworld.org>
date Tue, 04 Jan 2011 10:42:00 -0600
parents e5617047c926
children 535a891284da
files mercurial/subrepo.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/subrepo.py	Mon Jan 31 13:40:05 2011 +0100
+++ b/mercurial/subrepo.py	Tue Jan 04 10:42:00 2011 -0600
@@ -398,8 +398,8 @@
         if r == '' and not ignoreupdate: # no state recorded
             return True
         w = self._repo[None]
-        # version checked out changed?
         if w.p1() != self._repo[r] and not ignoreupdate:
+            # different version checked out
             return True
         return w.dirty() # working directory changed
 
@@ -744,8 +744,8 @@
                                (revision, self._relpath))
 
     def dirty(self, ignoreupdate=False):
-        # version checked out changed?
         if not ignoreupdate and self._state[1] != self._gitstate():
+            # different version checked out
             return True
         # check for staged changes or modified files; ignore untracked files
         out, code = self._gitdir(['diff-index', '--quiet', 'HEAD'])