log: do not redefine cachefunc in walkchangerevs
authorNicolas Dumazet <nicdumz.commits@gmail.com>
Tue, 20 Jul 2010 14:42:05 +0900
changeset 11635 4da35e02b67c
parent 11634 09147c065711
child 11644 c4f6f0a1bd5a
log: do not redefine cachefunc in walkchangerevs The same variable is defined a few blocks earlier. The first phases in walkchangerevs should in fact fill that cache, and allow faster lookups in the last phase. Redefining and overriding this cached function, (knowing that it will be called with the same arguments) defeats the caching purpose.
mercurial/cmdutil.py
--- a/mercurial/cmdutil.py	Wed Jul 21 09:43:45 2010 +0200
+++ b/mercurial/cmdutil.py	Tue Jul 20 14:42:05 2010 +0900
@@ -1182,7 +1182,6 @@
                 return rev in wanted
 
         for i, window in increasing_windows(0, len(revs)):
-            change = util.cachefunc(repo.changectx)
             nrevs = [rev for rev in revs[i:i + window] if want(rev)]
             for rev in sorted(nrevs):
                 fns = fncache.get(rev)