changeset 29407:20fabe814f89

revsets: use itervalues() where only values are needed I don't think there will be a noticeable speedup, but it removes an unused variable.
author Martin von Zweigbergk <martinvonz@google.com>
date Thu, 23 Jun 2016 13:08:10 -0700
parents c2193e59ef9f
children 785cadec2091
files mercurial/revset.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/revset.py	Thu Jun 23 12:39:05 2016 -0700
+++ b/mercurial/revset.py	Thu Jun 23 13:08:10 2016 -0700
@@ -1145,7 +1145,7 @@
     getargs(x, 0, 0, _("head takes no arguments"))
     hs = set()
     cl = repo.changelog
-    for b, ls in repo.branchmap().iteritems():
+    for ls in repo.branchmap().itervalues():
         hs.update(cl.rev(h) for h in ls)
     # XXX We should combine with subset first: 'subset & baseset(...)'. This is
     # necessary to ensure we preserve the order in subset.