comparison mercurial/revset.py @ 32923:2851b24eecc4

help: clarify ancestors() and descendants() include given set (issue5594) Also unified "a changeset" to "changesets".
author Yuya Nishihara <yuya@tcha.org>
date Sun, 18 Jun 2017 22:46:56 +0900
parents 582080a4a812
children 577759ef2ed2
comparison
equal deleted inserted replaced
32922:582080a4a812 32923:2851b24eecc4
245 s = dagop.revancestors(repo, heads, followfirst) 245 s = dagop.revancestors(repo, heads, followfirst)
246 return subset & s 246 return subset & s
247 247
248 @predicate('ancestors(set)', safe=True) 248 @predicate('ancestors(set)', safe=True)
249 def ancestors(repo, subset, x): 249 def ancestors(repo, subset, x):
250 """Changesets that are ancestors of a changeset in set. 250 """Changesets that are ancestors of changesets in set, including the
251 given changesets themselves.
251 """ 252 """
252 return _ancestors(repo, subset, x) 253 return _ancestors(repo, subset, x)
253 254
254 @predicate('_firstancestors', safe=True) 255 @predicate('_firstancestors', safe=True)
255 def _firstancestors(repo, subset, x): 256 def _firstancestors(repo, subset, x):
590 result = subset & result 591 result = subset & result
591 return result 592 return result
592 593
593 @predicate('descendants(set)', safe=True) 594 @predicate('descendants(set)', safe=True)
594 def descendants(repo, subset, x): 595 def descendants(repo, subset, x):
595 """Changesets which are descendants of changesets in set. 596 """Changesets which are descendants of changesets in set, including the
597 given changesets themselves.
596 """ 598 """
597 return _descendants(repo, subset, x) 599 return _descendants(repo, subset, x)
598 600
599 @predicate('_firstdescendants', safe=True) 601 @predicate('_firstdescendants', safe=True)
600 def _firstdescendants(repo, subset, x): 602 def _firstdescendants(repo, subset, x):