Mercurial > public > mercurial-scm > hg-stable
diff mercurial/merge.py @ 34355:1a5abc45e2fa
py3: explicitly convert dict.keys() and dict.items() into a list
Differential Revision: https://phab.mercurial-scm.org/D853
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Sat, 30 Sep 2017 15:45:15 +0530 |
parents | 440ece43024c |
children | 6f49ea88d984 |
line wrap: on
line diff
--- a/mercurial/merge.py Sat Sep 30 18:02:53 2017 +0530 +++ b/mercurial/merge.py Sat Sep 30 15:45:15 2017 +0530 @@ -1029,7 +1029,7 @@ # bids is a mapping from action method to list af actions # Consensus? if len(bids) == 1: # all bids are the same kind of method - m, l = bids.items()[0] + m, l = list(bids.items())[0] if all(a == l[0] for a in l[1:]): # len(bids) is > 1 repo.ui.note(_(" %s: consensus for %s\n") % (f, m)) actions[f] = l[0] @@ -1055,7 +1055,7 @@ for _f, args, msg in l: repo.ui.note(' %s -> %s\n' % (msg, m)) # Pick random action. TODO: Instead, prompt user when resolving - m, l = bids.items()[0] + m, l = list(bids.items())[0] repo.ui.warn(_(' %s: ambiguous merge - picked %s action\n') % (f, m)) actions[f] = l[0]