# HG changeset patch # User Matt Mackall # Date 2012-01-17 23:48:59 # Node ID 0329d3b12d8e39409c751c3954bd5005616e5212 # Parent 4252d9f08d7ecb1aa2df7696358af8dafc9547b3 revset: roots needs to be computed on full set diff --git a/mercurial/revset.py b/mercurial/revset.py --- a/mercurial/revset.py +++ b/mercurial/revset.py @@ -325,7 +325,7 @@ def _children(repo, narrow, s): cs = set() pr = repo.changelog.parentrevs s = set(s) - for r in narrow: + for r in xrange(len(repo)): for p in pr(r): if p in s: cs.add(r) @@ -776,7 +776,7 @@ def roots(repo, subset, x): """``roots(set)`` Changesets with no parent changeset in set. """ - s = getset(repo, subset, x) + s = getset(repo, xrange(len(repo)), x) cs = _children(repo, s, s) return [r for r in s if r not in cs]