Mercurial > public > mercurial-scm > hg
comparison mercurial/revset.py @ 44699:bcc1846e0f2b
revset: mark `successors()` experimental
Differential Revision: https://phab.mercurial-scm.org/D8406
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 13 Apr 2020 12:17:52 -0400 |
parents | 1ac74f653fa5 |
children | 7834da4b00fa |
comparison
equal
deleted
inserted
replaced
44698:1ac74f653fa5 | 44699:bcc1846e0f2b |
---|---|
2438 return smartset.baseset(result - repo.changelog.filteredrevs) | 2438 return smartset.baseset(result - repo.changelog.filteredrevs) |
2439 | 2439 |
2440 | 2440 |
2441 @predicate(b'successors(set)', safe=True) | 2441 @predicate(b'successors(set)', safe=True) |
2442 def successors(repo, subset, x): | 2442 def successors(repo, subset, x): |
2443 """All successors for set, including the given set themselves""" | 2443 """All successors for set, including the given set themselves. |
2444 (EXPERIMENTAL)""" | |
2444 s = getset(repo, fullreposet(repo), x) | 2445 s = getset(repo, fullreposet(repo), x) |
2445 f = lambda nodes: obsutil.allsuccessors(repo.obsstore, nodes) | 2446 f = lambda nodes: obsutil.allsuccessors(repo.obsstore, nodes) |
2446 d = _mapbynodefunc(repo, s, f) | 2447 d = _mapbynodefunc(repo, s, f) |
2447 return subset & d | 2448 return subset & d |
2448 | 2449 |