[PATCH] _lazymanifest: drop unnecessary call to sorted()

Martin von Zweigbergk martinvonz at google.com
Sun Mar 29 06:15:15 UTC 2015


# HG changeset patch
# User Martin von Zweigbergk <martinvonz at google.com>
# Date 1427514954 25200
#      Fri Mar 27 20:55:54 2015 -0700
# Node ID d9cc0d84339732f87b072688b0624d49fdf5436a
# Parent  efa094701a05d58d505c3b0c3b3c73dba4e51e97
_lazymanifest: drop unnecessary call to sorted()

The entries returned from _lazymanifest.iterentries() are already
sorted.

diff -r efa094701a05 -r d9cc0d843397 mercurial/manifest.py
--- a/mercurial/manifest.py	Fri Mar 27 14:11:13 2015 -0700
+++ b/mercurial/manifest.py	Fri Mar 27 20:55:54 2015 -0700
@@ -87,7 +87,7 @@
 
     def text(self):
         """Get the full data of this manifest as a bytestring."""
-        fl = sorted(self.iterentries())
+        fl = self.iterentries()
 
         _hex = revlog.hex
         # if this is changed to support newlines in filenames,


More information about the Mercurial-devel mailing list