# HG changeset patch # User Martin von Zweigbergk # Date 2016-06-23 20:08:10 # Node ID 20fabe814f89fd5a2a75c19de79507e460759a2a # Parent c2193e59ef9f0435a62ee2cc3c5cb8d260dfe1a2 revsets: use itervalues() where only values are needed I don't think there will be a noticeable speedup, but it removes an unused variable. diff --git a/mercurial/revset.py b/mercurial/revset.py --- a/mercurial/revset.py +++ b/mercurial/revset.py @@ -1145,7 +1145,7 @@ def head(repo, subset, x): 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.