diff mercurial/dirstate.py @ 35878:6e7fae8f1c6c

contrib: fix dirstatenonnormalcheck to work in Python 3 This is a redo of D1963 that has the added benefit of not breaking Python 2. Oops. # skip-blame because this is bytes prefixes and a s/iteritems/items/ Differential Revision: https://phab.mercurial-scm.org/D1970
author Augie Fackler <augie@google.com>
date Thu, 01 Feb 2018 16:01:43 -0500
parents bf367a93f000
children 265e91da56fd
line wrap: on
line diff
--- a/mercurial/dirstate.py	Thu Jan 18 13:12:09 2018 -0500
+++ b/mercurial/dirstate.py	Thu Feb 01 16:01:43 2018 -0500
@@ -1237,9 +1237,12 @@
         util.clearcachedproperty(self, "nonnormalset")
         util.clearcachedproperty(self, "otherparentset")
 
-    def iteritems(self):
+    def items(self):
         return self._map.iteritems()
 
+    # forward for python2,3 compat
+    iteritems = items
+
     def __len__(self):
         return len(self._map)