diff mercurial/dirstate.py @ 5123:79373ec3f27d

merge with crew-stable
author Alexis S. L. Carvalho <alexis@cecm.usp.br>
date Mon, 06 Aug 2007 01:00:10 -0300
parents 8b1ee1f59b3c b304c2496f52
children 90d9ec0dc69d
line wrap: on
line diff
--- a/mercurial/dirstate.py	Sun Aug 05 12:09:55 2007 -0700
+++ b/mercurial/dirstate.py	Mon Aug 06 01:00:10 2007 -0300
@@ -250,8 +250,14 @@
         except KeyError:
             self._ui.warn(_("not in dirstate: %s!\n") % f)
 
+    def clear(self):
+        self._map = {}
+        self._copymap = {}
+        self._pl = [nullid, nullid]
+        self._dirty = True
+
     def rebuild(self, parent, files):
-        self.invalidate()
+        self.clear()
         for f in files:
             if files.execf(f):
                 self._map[f] = ('n', 0777, -1, 0)