Show More
@@ -283,7 +283,7 b' def dagrange(repo, subset, x, y):' | |||||
283 | r = spanset(repo) |
|
283 | r = spanset(repo) | |
284 | xs = _revsbetween(repo, getset(repo, r, x), getset(repo, r, y)) |
|
284 | xs = _revsbetween(repo, getset(repo, r, x), getset(repo, r, y)) | |
285 | s = subset.set() |
|
285 | s = subset.set() | |
286 |
return xs.filter( |
|
286 | return xs.filter(s.__contains__) | |
287 |
|
287 | |||
288 | def andset(repo, subset, x, y): |
|
288 | def andset(repo, subset, x, y): | |
289 | return getset(repo, getset(repo, subset, x), y) |
|
289 | return getset(repo, getset(repo, subset, x), y) | |
@@ -348,7 +348,7 b' def _ancestors(repo, subset, x, followfi' | |||||
348 | if not args: |
|
348 | if not args: | |
349 | return baseset([]) |
|
349 | return baseset([]) | |
350 | s = _revancestors(repo, args, followfirst) |
|
350 | s = _revancestors(repo, args, followfirst) | |
351 |
return subset.filter( |
|
351 | return subset.filter(s.__contains__) | |
352 |
|
352 | |||
353 | def ancestors(repo, subset, x): |
|
353 | def ancestors(repo, subset, x): | |
354 | """``ancestors(set)`` |
|
354 | """``ancestors(set)`` | |
@@ -376,7 +376,7 b' def ancestorspec(repo, subset, x, n):' | |||||
376 | for i in range(n): |
|
376 | for i in range(n): | |
377 | r = cl.parentrevs(r)[0] |
|
377 | r = cl.parentrevs(r)[0] | |
378 | ps.add(r) |
|
378 | ps.add(r) | |
379 |
return subset.filter( |
|
379 | return subset.filter(ps.__contains__) | |
380 |
|
380 | |||
381 | def author(repo, subset, x): |
|
381 | def author(repo, subset, x): | |
382 | """``author(string)`` |
|
382 | """``author(string)`` | |
@@ -406,7 +406,7 b' def only(repo, subset, x):' | |||||
406 | exclude = getset(repo, spanset(repo), args[1]) |
|
406 | exclude = getset(repo, spanset(repo), args[1]) | |
407 |
|
407 | |||
408 | results = set(ancestormod.missingancestors(include, exclude, cl.parentrevs)) |
|
408 | results = set(ancestormod.missingancestors(include, exclude, cl.parentrevs)) | |
409 |
return lazyset(subset, |
|
409 | return lazyset(subset, results.__contains__) | |
410 |
|
410 | |||
411 | def bisect(repo, subset, x): |
|
411 | def bisect(repo, subset, x): | |
412 | """``bisect(string)`` |
|
412 | """``bisect(string)`` | |
@@ -423,7 +423,7 b' def bisect(repo, subset, x):' | |||||
423 | # i18n: "bisect" is a keyword |
|
423 | # i18n: "bisect" is a keyword | |
424 | status = getstring(x, _("bisect requires a string")).lower() |
|
424 | status = getstring(x, _("bisect requires a string")).lower() | |
425 | state = set(hbisect.get(repo, status)) |
|
425 | state = set(hbisect.get(repo, status)) | |
426 |
return subset.filter( |
|
426 | return subset.filter(state.__contains__) | |
427 |
|
427 | |||
428 | # Backward-compatibility |
|
428 | # Backward-compatibility | |
429 | # - no help entry so that we do not advertise it any more |
|
429 | # - no help entry so that we do not advertise it any more | |
@@ -466,7 +466,7 b' def bookmark(repo, subset, x):' | |||||
466 |
|
466 | |||
467 | bms = set([repo[r].rev() |
|
467 | bms = set([repo[r].rev() | |
468 | for r in repo._bookmarks.values()]) |
|
468 | for r in repo._bookmarks.values()]) | |
469 |
return subset.filter( |
|
469 | return subset.filter(bms.__contains__) | |
470 |
|
470 | |||
471 | def branch(repo, subset, x): |
|
471 | def branch(repo, subset, x): | |
472 | """``branch(string or set)`` |
|
472 | """``branch(string or set)`` | |
@@ -725,7 +725,7 b' def destination(repo, subset, x):' | |||||
725 | r = src |
|
725 | r = src | |
726 | src = _getrevsource(repo, r) |
|
726 | src = _getrevsource(repo, r) | |
727 |
|
727 | |||
728 |
return subset.filter( |
|
728 | return subset.filter(dests.__contains__) | |
729 |
|
729 | |||
730 | def divergent(repo, subset, x): |
|
730 | def divergent(repo, subset, x): | |
731 | """``divergent()`` |
|
731 | """``divergent()`` | |
@@ -734,7 +734,7 b' def divergent(repo, subset, x):' | |||||
734 | # i18n: "divergent" is a keyword |
|
734 | # i18n: "divergent" is a keyword | |
735 | getargs(x, 0, 0, _("divergent takes no arguments")) |
|
735 | getargs(x, 0, 0, _("divergent takes no arguments")) | |
736 | divergent = obsmod.getrevs(repo, 'divergent') |
|
736 | divergent = obsmod.getrevs(repo, 'divergent') | |
737 |
return subset.filter( |
|
737 | return subset.filter(divergent.__contains__) | |
738 |
|
738 | |||
739 | def draft(repo, subset, x): |
|
739 | def draft(repo, subset, x): | |
740 | """``draft()`` |
|
740 | """``draft()`` | |
@@ -811,7 +811,7 b' def filelog(repo, subset, x):' | |||||
811 | for fr in fl: |
|
811 | for fr in fl: | |
812 | s.add(fl.linkrev(fr)) |
|
812 | s.add(fl.linkrev(fr)) | |
813 |
|
813 | |||
814 |
return subset.filter( |
|
814 | return subset.filter(s.__contains__) | |
815 |
|
815 | |||
816 | def first(repo, subset, x): |
|
816 | def first(repo, subset, x): | |
817 | """``first(set, [n])`` |
|
817 | """``first(set, [n])`` | |
@@ -834,7 +834,7 b' def _follow(repo, subset, x, name, follo' | |||||
834 | else: |
|
834 | else: | |
835 | s = _revancestors(repo, baseset([c.rev()]), followfirst) |
|
835 | s = _revancestors(repo, baseset([c.rev()]), followfirst) | |
836 |
|
836 | |||
837 |
return subset.filter( |
|
837 | return subset.filter(s.__contains__) | |
838 |
|
838 | |||
839 | def follow(repo, subset, x): |
|
839 | def follow(repo, subset, x): | |
840 | """``follow([file])`` |
|
840 | """``follow([file])`` | |
@@ -1176,7 +1176,7 b' def origin(repo, subset, x):' | |||||
1176 | src = prev |
|
1176 | src = prev | |
1177 |
|
1177 | |||
1178 | o = set([_firstsrc(r) for r in args]) |
|
1178 | o = set([_firstsrc(r) for r in args]) | |
1179 |
return subset.filter( |
|
1179 | return subset.filter(o.__contains__) | |
1180 |
|
1180 | |||
1181 | def outgoing(repo, subset, x): |
|
1181 | def outgoing(repo, subset, x): | |
1182 | """``outgoing([path])`` |
|
1182 | """``outgoing([path])`` | |
@@ -1199,7 +1199,7 b' def outgoing(repo, subset, x):' | |||||
1199 | repo.ui.popbuffer() |
|
1199 | repo.ui.popbuffer() | |
1200 | cl = repo.changelog |
|
1200 | cl = repo.changelog | |
1201 | o = set([cl.rev(r) for r in outgoing.missing]) |
|
1201 | o = set([cl.rev(r) for r in outgoing.missing]) | |
1202 |
return subset.filter( |
|
1202 | return subset.filter(o.__contains__) | |
1203 |
|
1203 | |||
1204 | def p1(repo, subset, x): |
|
1204 | def p1(repo, subset, x): | |
1205 | """``p1([set])`` |
|
1205 | """``p1([set])`` |
General Comments 0
You need to be logged in to leave comments.
Login now