Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 3531:730ca93ed788
convert dict(zip(x,x)) to dict.fromkeys(x)
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Fri, 27 Oct 2006 00:38:42 -0500 |
parents | cd2216599c99 |
children | 23f7d9621783 |
line wrap: on
line diff
--- a/mercurial/commands.py Thu Oct 26 23:59:21 2006 -0500 +++ b/mercurial/commands.py Fri Oct 27 00:38:42 2006 -0500 @@ -106,7 +106,7 @@ if not slowpath and not files: # No files, no patterns. Display all revs. - wanted = dict(zip(revs, revs)) + wanted = dict.fromkeys(revs) copies = [] if not slowpath: # Only files, no patterns. Check the history of each file. @@ -210,7 +210,7 @@ ff = followfilter() stop = min(revs[0], revs[-1]) for x in xrange(rev, stop-1, -1): - if ff.match(x) and wanted.has_key(x): + if ff.match(x) and x in wanted: del wanted[x] def iterate():