[darcs-users] Simple commutation theorems

David Roundy droundy at abridgegame.org
Thu Nov 27 12:38:20 UTC 2003


On Wed, Nov 26, 2003 at 07:17:13AM -0500, David Roundy wrote:
> To clarify the conjecture, it is that
> 
> if P;Q commute then
> 
> either P;Q commutes to Q';P
> or P;Q commutes to Q;P'

I've realized that although this conjecture may be true for existing patch
types, it isn't true for a couple of planned patch types.

The line-wrapped word hunk patch (which doesn't yet have a good name).  The
reason is that the line-wrapped word hunk patch will include context, and
any patch that includes context will violate the above conjecture.  And
including context in the l-w-w-h patch is important, because without any
context the l-w-w-h patch could never be commuted with an ordinary hunk
patch.  And in the darcs repo I expect to mix the two patchs extensively
because darcs is written in the literate style mixing latex (which is best
described using lwwh patches) with haskell code, which definitely requires
conventional hunk patches.

Another patch type that won't include context but will violate the above
conjecture is the indent type (which will change the level of indentation
for a contiguous set of lines).  This should commute with a hunk patch that
is entirely contained within the indent patch (provided the indent patch is
applicable to the new lines), but this will change both the hunk (since it
is getting indented/unindented) and the indent (since its number of lines
may change).
-- 
David Roundy
http://www.abridgegame.org




More information about the darcs-users mailing list