Patch 1879 rewrite Merge FL instance in terms of Me... (and 1 more)

Title rewrite Merge FL instance in terms of Me... (and 1 more)
Superseder Nosy List ganesh
Related Issues
Status followup-requested Assigned To ganesh

Created on 2019-08-15.23:23:09 by ganesh, last changed 2020-06-20.09:06:20 by bf.

File name Status Uploaded Type Edit Remove
patch-preview.txt ganesh, 2019-08-15.23:23:08 text/x-darcs-patch
rewrite-merge-fl-instance-in-terms-of-mergefn-combinators.dpatch ganesh, 2019-08-15.23:23:08 application/x-darcs-patch
unnamed ganesh, 2019-08-15.23:23:08 text/plain
See mailing list archives for discussion on individual patches.
msg21114 (view) Author: ganesh Date: 2019-08-15.23:23:08
Is there any reason not to make these changes?
I just wanted Merge RL for some experiments I'm doing, but it
seems natural to have it anyway.

2 patches for repository darcs-unstable@darcs.net:screened:

patch aa941bfe30984266888b74e4b16e318595fe7be7
Author: Ganesh Sittampalam <ganesh@earth.li>
Date:   Thu Aug 15 23:26:41 BST 2019
  * rewrite Merge FL instance in terms of MergeFn combinators

patch 7c4c31258e3dca408d8be0fba08b8373726e4fb2
Author: Ganesh Sittampalam <ganesh@earth.li>
Date:   Thu Aug 15 23:31:06 BST 2019
  * add merge instance for RL
msg21119 (view) Author: bf Date: 2019-08-16.07:06:31
No principle objections.

But note that flipMerger is the same as swapMerge and we should have
only one of them (I don't care where it lives and how it is named).

Also, I am missing haddocks and properties for the new functions. E.g.
is your instance Merge RL equivalent to first reversing both sequences
and then re-reversing the result? (I think so)

As a last remark, I always felt the "natural" equivalent operation for
RLs should rather be

unmerge :: RL (p :/\: p) wX wY -> RL (p :/\: p) wX wY

The reason is laziness: Merging is a total function and thus the result
can be consumed lazily. But your definition (I believe this is true for
any definition) for RL does not allow that, I think. Whereas unmerge is
naturally lazy for RLs.
Date User Action Args
2019-08-15 23:23:09ganeshcreate
2019-08-16 07:06:31bfsetmessages: + msg21119
2019-08-25 15:08:22ganeshsetstatus: needs-screening -> followup-requested
assignedto: ganesh
2020-06-20 09:05:27bfsetstatus: followup-requested -> accepted
2020-06-20 09:06:20bfsetstatus: accepted -> followup-requested