# HG changeset patch # User Matt Mackall # Date 1289862043 21600 # Node ID acd69df118ab1e81cb5e3fa90cd2b33f2f7aabe4 # Parent 827aa0992ceac9aed184dddd915bf3ade527794f context: walk both parents for workingctx.ancestors() diff -r 827aa0992cea -r acd69df118ab mercurial/context.py --- a/mercurial/context.py Mon Nov 15 10:55:54 2010 -0600 +++ b/mercurial/context.py Mon Nov 15 17:00:43 2010 -0600 @@ -818,6 +818,11 @@ finally: wlock.release() + def ancestors(self): + for a in self._repo.changelog.ancestors( + *[p.rev() for p in self._parents]): + yield changectx(self._repo, a) + def remove(self, list, unlink=False): if unlink: for f in list: