Mercurial > public > mercurial-scm > hg-stable
diff mercurial/revset.py @ 50430:386737600689
revset: add `_internal()` predicate
This predicate help core code to select internal changeset (in the internal
phase).
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 08 Mar 2023 11:00:30 +0100 |
parents | 92f71d40fc1d |
children | 18c8c18993f0 |
line wrap: on
line diff
--- a/mercurial/revset.py Fri Mar 10 03:41:18 2023 +0100 +++ b/mercurial/revset.py Wed Mar 08 11:00:30 2023 +0100 @@ -1967,6 +1967,12 @@ return repo._phasecache.getrevset(repo, targets, subset) +@predicate(b'_internal()', safe=True) +def _internal(repo, subset, x): + getargs(x, 0, 0, _(b"_internal takes no arguments")) + return _phase(repo, subset, *phases.all_internal_phases) + + @predicate(b'_phase(idx)', safe=True) def phase(repo, subset, x): l = getargs(x, 1, 1, b"_phase requires one argument")