Mercurial > hg
comparison mercurial/revset.py @ 42440:d279e4f453c4
revset: use nullrev constant in merge()
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sun, 09 Jun 2019 22:18:22 +0900 |
parents | 6bc1245cd598 |
children | 43c8f72184f4 |
comparison
equal
deleted
inserted
replaced
42439:aae93201f758 | 42440:d279e4f453c4 |
---|---|
1359 """Changeset is a merge changeset. | 1359 """Changeset is a merge changeset. |
1360 """ | 1360 """ |
1361 # i18n: "merge" is a keyword | 1361 # i18n: "merge" is a keyword |
1362 getargs(x, 0, 0, _("merge takes no arguments")) | 1362 getargs(x, 0, 0, _("merge takes no arguments")) |
1363 cl = repo.changelog | 1363 cl = repo.changelog |
1364 return subset.filter(lambda r: cl.parentrevs(r)[1] != -1, | 1364 nullrev = node.nullrev |
1365 return subset.filter(lambda r: cl.parentrevs(r)[1] != nullrev, | |
1365 condrepr='<merge>') | 1366 condrepr='<merge>') |
1366 | 1367 |
1367 @predicate('branchpoint()', safe=True) | 1368 @predicate('branchpoint()', safe=True) |
1368 def branchpoint(repo, subset, x): | 1369 def branchpoint(repo, subset, x): |
1369 """Changesets with more than one child. | 1370 """Changesets with more than one child. |