Mercurial > hg-stable
changeset 8453:d1ca637b0773
revlog.missing(): use sets instead of a dict
author | Benoit Boissinot <benoit.boissinot@ens-lyon.org> |
---|---|
date | Sun, 17 May 2009 02:44:12 +0200 |
parents | e1f4343db740 |
children | 6d4bf1c1a003 |
files | mercurial/revlog.py |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/revlog.py Sun May 17 01:16:56 2009 +0200 +++ b/mercurial/revlog.py Sun May 17 02:44:12 2009 +0200 @@ -624,18 +624,18 @@ has.update(common) # take all ancestors from heads that aren't in has - missing = {} + missing = set() visit = [r for r in heads if r not in has] while visit: r = visit.pop(0) if r in missing: continue else: - missing[r] = None + missing.add(r) for p in self.parentrevs(r): if p not in has: visit.append(p) - missing = missing.keys() + missing = list(missing) missing.sort() return [self.node(r) for r in missing]