Mercurial > hg
changeset 12999:acd69df118ab stable
context: walk both parents for workingctx.ancestors()
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Mon, 15 Nov 2010 17:00:43 -0600 |
parents | 827aa0992cea |
children | 417f3c27983b |
files | mercurial/context.py |
diffstat | 1 files changed, 5 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- 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: