Show More
@@ -364,13 +364,12 b' def checkstatus(repo, subset, pat, field' | |||
|
364 | 364 | break |
|
365 | 365 | return s |
|
366 | 366 | |
|
367 | def _children(repo, narrow, s): | |
|
367 | def _children(repo, narrow, parentset): | |
|
368 | 368 | cs = set() |
|
369 | 369 | pr = repo.changelog.parentrevs |
|
370 | s = set(s) | |
|
371 | for r in xrange(len(repo)): | |
|
370 | for r in narrow: | |
|
372 | 371 | for p in pr(r): |
|
373 | if p in s: | |
|
372 | if p in parentset: | |
|
374 | 373 | cs.add(r) |
|
375 | 374 | return cs |
|
376 | 375 | |
@@ -378,7 +377,7 b' def children(repo, subset, x):' | |||
|
378 | 377 | """``children(set)`` |
|
379 | 378 | Child changesets of changesets in set. |
|
380 | 379 | """ |
|
381 | s = getset(repo, range(len(repo)), x) | |
|
380 | s = set(getset(repo, range(len(repo)), x)) | |
|
382 | 381 | cs = _children(repo, subset, s) |
|
383 | 382 | return [r for r in subset if r in cs] |
|
384 | 383 | |
@@ -994,11 +993,12 b' def reverse(repo, subset, x):' | |||
|
994 | 993 | |
|
995 | 994 | def roots(repo, subset, x): |
|
996 | 995 | """``roots(set)`` |
|
997 | Changesets with no parent changeset in set. | |
|
996 | Changesets in set with no parent changeset in set. | |
|
998 | 997 | """ |
|
999 | s = getset(repo, xrange(len(repo)), x) | |
|
1000 | cs = _children(repo, s, s) | |
|
1001 | return [r for r in s if r not in cs] | |
|
998 | s = set(getset(repo, xrange(len(repo)), x)) | |
|
999 | subset = [r for r in subset if r in s] | |
|
1000 | cs = _children(repo, subset, s) | |
|
1001 | return [r for r in subset if r not in cs] | |
|
1002 | 1002 | |
|
1003 | 1003 | def secret(repo, subset, x): |
|
1004 | 1004 | """``secret()`` |
General Comments 0
You need to be logged in to leave comments.
Login now