diff mercurial/dirstate.py @ 15791:a814f8fcc65a

Use explicit integer division Found by running the test suite with the -3 flag to show places where we have int / int division that can be replaced with int // int.
author Martin Geisler <mg@aragost.com>
date Sun, 08 Jan 2012 18:15:54 +0100
parents d6c19cfa03ce
children bfd3ce759682
line wrap: on
line diff
--- a/mercurial/dirstate.py	Sun Jan 08 17:57:25 2012 +0100
+++ b/mercurial/dirstate.py	Sun Jan 08 18:15:54 2012 +0100
@@ -49,7 +49,7 @@
         self._rootdir = os.path.join(root, '')
         self._dirty = False
         self._dirtypl = False
-        self._lastnormaltime = None
+        self._lastnormaltime = 0
         self._ui = ui
 
     @propertycache
@@ -251,7 +251,7 @@
                 "_ignore"):
             if a in self.__dict__:
                 delattr(self, a)
-        self._lastnormaltime = None
+        self._lastnormaltime = 0
         self._dirty = False
 
     def copy(self, source, dest):
@@ -415,7 +415,7 @@
             delattr(self, "_dirs")
         self._copymap = {}
         self._pl = [nullid, nullid]
-        self._lastnormaltime = None
+        self._lastnormaltime = 0
         self._dirty = True
 
     def rebuild(self, parent, files):
@@ -463,7 +463,7 @@
             write(f)
         st.write(cs.getvalue())
         st.close()
-        self._lastnormaltime = None
+        self._lastnormaltime = 0
         self._dirty = self._dirtypl = False
 
     def _dirignore(self, f):