Send original copy to merge

This commit is contained in:
Jared Hance 2014-07-29 14:16:35 -04:00
parent 68fb76214d
commit 3e0b18494c
2 changed files with 16 additions and 8 deletions

View File

@ -635,6 +635,11 @@
|* [a=(unit) b=*]
?~(a b u.a)
::
++ lift :: lift gate (fmap)
|* a=gate :: flipped
|* b=(unit) :: curried
(bind b a) :: bind
::
++ mate :: choose
|* [a=(unit) b=(unit)]
?~ b
@ -649,7 +654,7 @@
!!
u.a
::
++ some :: lift
++ some :: lift (pure)
|* a=*
[~ u=a]
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

View File

@ -1333,7 +1333,7 @@
==
::
++ qeal :: merge p,q
|= [p=miso q=miso]
|= [p=miso q=miso r=(list)]
^- miso
~| %qeal-fail
?> ?=(%mut -.p)
@ -1377,7 +1377,7 @@
~| %quil-conflict !!
==
++ quil :: merge p,q
|= [p=(unit miso) q=(unit miso)]
|= [p=(unit miso) q=(unit miso) r=(unit (list))]
^- (unit miso)
?~ p q :: trivial
?~ q p :: trivial
@ -1386,8 +1386,8 @@
?. ?=(%mut -.u.q)
~| %quil-conflict !!
%- some
%+ qeal u.p :: merge p,q'
u.q
%^ qeal u.p u.q :: merge p,q
%- need r
::
++ meld :: merge p,q from r
|= [p=yaki q=yaki r=yaki]
@ -1409,9 +1409,12 @@
|= [pat=path res=(map path blob)]
=+ ^= v
%- need
%+ quil
(~(get by s) pat)
(~(get by t) pat)
%^ quil (~(get by s) pat)
(~(get by t) pat)
%- %- lift %- hard (list)
%- %- lift zaul
%- ~(get by q.r)
pat
?- -.v
%del res :: no longer exists
%ins :: new file