# HG changeset patch # User Martin Geisler # Date 1313583106 -7200 # Node ID 3afe5edda4e39fdae59597c87d00de8e1d7771bf # Parent c981f4a9ea74ef0a40da1e8bfb41ce3dc9570d34 merge: use repo.ui directly instead local variable The non-standard 'u = repo.ui' shorthand was only used two times and there were many other full references to repo.ui. diff -r c981f4a9ea74 -r 3afe5edda4e3 mercurial/merge.py --- a/mercurial/merge.py Thu Aug 11 22:40:43 2011 -0500 +++ b/mercurial/merge.py Wed Aug 17 14:11:46 2011 +0200 @@ -273,7 +273,6 @@ action.sort(key=actionkey) # prescan for merges - u = repo.ui for a in action: f, m = a[:2] if m == 'm': # merge @@ -308,8 +307,8 @@ numupdates = len(action) for i, a in enumerate(action): f, m = a[:2] - u.progress(_('updating'), i + 1, item=f, total=numupdates, - unit=_('files')) + repo.ui.progress(_('updating'), i + 1, item=f, total=numupdates, + unit=_('files')) if f and f[0] == "/": continue if m == "r": # remove @@ -377,7 +376,7 @@ repo.wopener.audit(f) util.setflags(repo.wjoin(f), 'l' in flags, 'x' in flags) ms.commit() - u.progress(_('updating'), None, total=numupdates, unit=_('files')) + repo.ui.progress(_('updating'), None, total=numupdates, unit=_('files')) return updated, merged, removed, unresolved