Here are various tweaks to patch-related code. Mostly factored out of my
rebase branch, so some have no obvious immediate value but will help
when merging that later.
Commentary on some of the patches inline:
12 patches for repository darcs-unstable@darcs.net:screened:
Just trying to reduce the dependency on the Patchy class:
Tue May 15 21:52:50 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* drop some unnecessary Patchy constraints
This helps to simplify a type class - it's a method that actually
proved quite problematic when implementing new patch types, and
this is the last in a line of patches to get rid of it:
Wed May 16 07:00:12 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* get rid of joinPatches
Trying to cut down the over-large (IMO) Patchy class:
Wed May 16 08:00:17 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* drop MyEq superclass from Patchy
The notion of equality on patches isn't completely obvious,
because it might be structural equality or equality under commutations
(e.g. for lists of patches).
So it's better to be explicit about when we need it.
It moves into PrimPatch instead for now, for V1 and V2 commutation,
but RealPatch doesn't need it.
This one makes it easier to temporarily drop in debugging code
into generic patch handling code:
Wed May 16 18:36:47 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* add helper class for debugging patches
Making complicated commutes out of simpler commutes, e.g. commuting
lists of patches:
Thu May 17 17:43:18 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* break CommuteFn infrastructure out into separate module
More patch simplification:
Thu May 17 17:55:01 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* drop unnecessary superclasses and move Invert FL/RL instances
Thu May 17 17:55:35 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* add commutation combinators for Named
Thu May 17 18:20:17 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* add utility function for changing type of a ListFormat
Thu May 17 18:35:39 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* add merge combinators
Makes it easier to use resolution code from rebase:
Thu May 31 18:47:36 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* relax type signature
Thu May 31 18:47:58 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* use RepoPatch instead of Patchy constraint for matchers
This isn't required by the code, but it helps to guard against accidentally
using the wrong kind of patch.
Thu May 31 18:48:28 BST 2012 Ganesh Sittampalam <ganesh@earth.li>
* make Patchy smaller
Reading, printing and inspecting the internals are now separate
which makes it easier to see what functionality is needed where.
Patchy is left as a core: Apply, Commute and Invert.
Attachments
|