Reverse the way backout is doing the merge

Gilles Moris gilles.moris at free.fr
Thu Feb 21 06:49:11 CST 2008


On Thursday 21 February 2008 11:37:54 am Peter Arrenbrecht wrote:
> On Thu, Feb 21, 2008 at 11:15 AM, Martin Sjögren
> <martin.sjogren at jasper-da.com> wrote:
> > tor 2008-02-21 klockan 10:35 +0100 skrev Peter Arrenbrecht:
> >
> > > I believe this proposal is related to
> >  >
> >  >   http://www.venge.net/mtn-wiki/DaggyFixes
> >  >
> >  > The current behaviour seems to be daggy, the proposed one not. From a
> >  > theoretical point of view I would prefer the daggy behaviour. However,
> >  > I have no practical experience with backout, so I cannot comment on
> >  > its actual usability.
> >
> >  If I understand correctly, the diffs you see in a merge changeset is
> >  towards the "first" child node, which is somewhat arbitrary, and what
> >  the proposed change does is swap which is the "first" child in the merge
> >  between the backout changeset and whatever you're merging with.
> >
> >  If I've understood correctly :-) this sounds like a good change, making
> >  the diff from merging in a backout changeset more intuitive.
> 
> So do I understand correctly that the current behaviour when undoing B
> in A -> B -> C -> D is:
> 
> A -> B --> C -> D --> E
>        \          /
>         -> !B --->
> 
> where the first parent of E is D and the proposed change simply
> switches parents for E but leaves the layout of the DAG as is? If so,
> then fine with me.
Yes that's it: it is just the order of the parent that will be different.
Before the patch, the first parent would be !B and the second D.
After, it is just the reverse. The graph itself does not change.
> 
> >  I can't see how you could end up with a history that's NOT a dag
> >  (directed acyclic graph), wouldn't that be rather impossible?
> 
> Sure. The point was what the DAG looks like.
> -peo
> 
> _______________________________________________
> Mercurial mailing list
> Mercurial at selenic.com
> http://selenic.com/mailman/listinfo/mercurial
> 





More information about the Mercurial mailing list