Show More
@@ -1129,11 +1129,14 b' def head(repo, subset, x):' | |||||
1129 | hs.update(cl.rev(h) for h in ls) |
|
1129 | hs.update(cl.rev(h) for h in ls) | |
1130 | return subset & baseset(hs) |
|
1130 | return subset & baseset(hs) | |
1131 |
|
1131 | |||
1132 | @predicate('heads(set)', safe=True) |
|
1132 | @predicate('heads(set)', safe=True, takeorder=True) | |
1133 | def heads(repo, subset, x): |
|
1133 | def heads(repo, subset, x, order): | |
1134 | """Members of set with no children in set. |
|
1134 | """Members of set with no children in set. | |
1135 | """ |
|
1135 | """ | |
1136 | s = getset(repo, subset, x) |
|
1136 | # argument set should never define order | |
|
1137 | if order == defineorder: | |||
|
1138 | order = followorder | |||
|
1139 | s = getset(repo, subset, x, order=order) | |||
1137 | ps = parents(repo, subset, x) |
|
1140 | ps = parents(repo, subset, x) | |
1138 | return s - ps |
|
1141 | return s - ps | |
1139 |
|
1142 |
@@ -1376,20 +1376,20 b' Test heads' | |||||
1376 | <baseset [9]>, set([0, 1, 2, 3, 4, 5, 6, 8])>>> |
|
1376 | <baseset [9]>, set([0, 1, 2, 3, 4, 5, 6, 8])>>> | |
1377 | 9 |
|
1377 | 9 | |
1378 |
|
1378 | |||
1379 |
|
|
1379 | but should follow the order of the subset | |
1380 |
|
1380 | |||
1381 | $ log 'heads(all())' |
|
1381 | $ log 'heads(all())' | |
1382 | 7 |
|
1382 | 7 | |
1383 | 9 |
|
1383 | 9 | |
1384 | $ log 'heads(tip:0)' |
|
1384 | $ log 'heads(tip:0)' | |
|
1385 | 7 | |||
1385 | 9 |
|
1386 | 9 | |
1386 | 7 |
|
|||
1387 | $ log 'tip:0 & heads(all())' |
|
1387 | $ log 'tip:0 & heads(all())' | |
1388 | 9 |
|
1388 | 9 | |
1389 | 7 |
|
1389 | 7 | |
1390 | $ log 'tip:0 & heads(0:tip)' |
|
1390 | $ log 'tip:0 & heads(0:tip)' | |
|
1391 | 9 | |||
1391 | 7 |
|
1392 | 7 | |
1392 | 9 |
|
|||
1393 |
|
1393 | |||
1394 | $ log 'keyword(issue)' |
|
1394 | $ log 'keyword(issue)' | |
1395 | 6 |
|
1395 | 6 |
General Comments 0
You need to be logged in to leave comments.
Login now