diff -r a82e138d5249 -r ae933e3e2226 mercurial/revset.py --- a/mercurial/revset.py Sun Aug 21 12:45:43 2016 +0900 +++ b/mercurial/revset.py Thu Sep 08 22:44:10 2016 +0900 @@ -2556,15 +2556,14 @@ if tree[0] == 'func' and tree[1][0] == 'symbol': return tree[1][1], getlist(tree[2]) -def expandaliases(ui, tree, showwarning=None): +def expandaliases(ui, tree): aliases = _aliasrules.buildmap(ui.configitems('revsetalias')) tree = _aliasrules.expand(aliases, tree) - if showwarning: - # warn about problematic (but not referred) aliases - for name, alias in sorted(aliases.iteritems()): - if alias.error and not alias.warned: - showwarning(_('warning: %s\n') % (alias.error)) - alias.warned = True + # warn about problematic (but not referred) aliases + for name, alias in sorted(aliases.iteritems()): + if alias.error and not alias.warned: + ui.warn(_('warning: %s\n') % (alias.error)) + alias.warned = True return tree def foldconcat(tree): @@ -2617,7 +2616,7 @@ tree = ('or',) + tuple(parse(s, lookup) for s in specs) if ui: - tree = expandaliases(ui, tree, showwarning=ui.warn) + tree = expandaliases(ui, tree) tree = foldconcat(tree) tree = analyze(tree) tree = optimize(tree)