[PATCH 3 of 3] merge: add file ancestor linknode to mergestate

Durham Goode durham at fb.com
Tue Jan 12 14:22:45 CST 2016


On 1/6/16 5:40 PM, Durham Goode wrote:
> # HG changeset patch
> # User Durham Goode <durham at fb.com>
> # Date 1452127911 28800
> #      Wed Jan 06 16:51:51 2016 -0800
> # Node ID a8adf78352f494c7cf88221bd346ecdda2a9cdfa
> # Parent  7afd0e010fd8d7fea0e6339f5f280fa192c1e176
> merge: add file ancestor linknode to mergestate
>
> During a merge, each file has a current filenode, an other filenode, and an
> ancestor filenode. The ancestor filenode's linknode is not stored though, and we
> rely on the ability for the filectx() to look up the linknode by using the
> revlog's linkrev. In alternative backends (like remotefilelog), linkrev's may
> not be present or may have restriction that prevent arbitrary linkrev look up
> given a filenode.
>
> This patch accounts for that by storing the ancestor filenode's linknode in the
> merge state so that it is available later at resolution time.
>
> This results in some minor test changes due to the extra state, and due to us no
> longer always using the earliest commit (i.e. the linkrev target) for that
> filenode (which is ok, since we're still using an ancestor of current and other
> that uses the correct filenode).
>
Ping! Given that this is an optional parameter, and is a dictionary (so 
extensible), I feel this shouldn't be too crazy of an accept.


More information about the Mercurial-devel mailing list