# HG changeset patch # User Durham Goode # Date 2014-12-18 17:37:14 # Node ID 11a160547d7f34ef986235f701282425242eb755 # Parent 7cfe58983bff24e3fb3bce99963511cb388c701b context: return dirstate parents in workingctx.ancestors() workingctx.ancestors() was not returning the dirstate parents as part of the result set. The only place this function is used is for copy detection when committing a file, and that code already checks the parents manually, so this change has no affect at the moment. I found it while playing around with changing how copy detection works. diff --git a/mercurial/context.py b/mercurial/context.py --- a/mercurial/context.py +++ b/mercurial/context.py @@ -1165,6 +1165,8 @@ class committablectx(basectx): return sorted(self._repo.dirstate.matches(match)) def ancestors(self): + for p in self._parents: + yield p for a in self._repo.changelog.ancestors( [p.rev() for p in self._parents]): yield changectx(self._repo, a)