commands: remove unused variable from heads command
authorMartin Geisler <mg@aragost.com>
Tue, 31 May 2011 09:59:03 +0200
changeset 14465 9e3a89c9e46c
parent 14464 00256f689f9c
child 14466 bd34a027f3ed
commands: remove unused variable from heads command The b variable has not been needed since fd511e9eeea6. Renamed ls variable to bheads for clarity.
mercurial/commands.py
--- a/mercurial/commands.py	Tue May 31 08:47:16 2011 +0200
+++ b/mercurial/commands.py	Tue May 31 09:59:03 2011 +0200
@@ -2522,15 +2522,15 @@
         heads = [repo[h] for h in repo.heads(start)]
     else:
         heads = []
-        for b, ls in repo.branchmap().iteritems():
+        for bheads in repo.branchmap().itervalues():
             if start is None:
-                heads += [repo[h] for h in ls]
+                heads += [repo[h] for h in bheads]
                 continue
             startrev = repo.changelog.rev(start)
             descendants = set(repo.changelog.descendants(startrev))
             descendants.add(startrev)
             rev = repo.changelog.rev
-            heads += [repo[h] for h in ls if rev(h) in descendants]
+            heads += [repo[h] for h in bheads if rev(h) in descendants]
 
     if branchrevs:
         branches = set(repo[br].branch() for br in branchrevs)