diff mercurial/cmdutil.py @ 17675:8575f4a2126e

clfilter: remove usage of `range` in favor of iteration over changelog If we want to apply filtering at changelog level, we need to iterate over it. See previous changeset description for details.
author Pierre-Yves David <pierre-yves.david@logilab.fr>
date Thu, 20 Sep 2012 19:01:53 +0200
parents 63e45aee46d4
children f87683a1b02a
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Mon Sep 03 14:19:45 2012 +0200
+++ b/mercurial/cmdutil.py	Thu Sep 20 19:01:53 2012 +0200
@@ -1394,7 +1394,8 @@
         if follow and len(repo) > 0:
             revs = scmutil.revrange(repo, ['.:0'])
         else:
-            revs = range(len(repo) - 1, -1, -1)
+            revs = list(repo.changelog)
+            revs.reverse()
     if not revs:
         return iter([]), None, None
     expr, filematcher = _makegraphlogrevset(repo, pats, opts, revs)