# HG changeset patch # User Boris Feld # Date 1534981719 -7200 # Node ID b17d27ea61fb0105abb53e74ff0973ba93574bd6 # Parent 31c0ee6eb0acbb532d63cf80f3e90ae9237be67f phase: use `_phase` revset instead of string interpolation The previous code was hackyer and assume all phases had an associated revset. The later might no longer be true once we introduce more internal phase. diff -r 31c0ee6eb0ac -r b17d27ea61fb mercurial/phases.py --- a/mercurial/phases.py Thu Aug 23 01:48:26 2018 +0200 +++ b/mercurial/phases.py Thu Aug 23 01:48:39 2018 +0200 @@ -599,7 +599,7 @@ # to update. This avoid creating empty transaction during no-op operation. for phase in allphases[:-1]: - revset = '%%ln - %s()' % phasenames[phase] + revset = '%%ln - _phase(%d)' % phase heads = [c.node() for c in repo.set(revset, headsbyphase[phase])] if heads: advanceboundary(repo, trgetter(), phase, heads)