on 492ae2f help sign in
50 lines 947 B history raw
1### `++furl`
3Unify changes
5Merge two [`++toro`]()s `one` and `two` that are in the same [`desk`]()
6and pointed at the same [`++path`]().
8Accepts
9-------
11`one` is a `++toro`.
13`two` is a `++toro`.
15Produces
16--------
18A `++toro`.
20Source
21------
23 ++ furl :: unify changes
24 |= [one=toro two=toro]
25 ^- toro
26 ~| %furl
27 ?> ?& =(p.one p.two) :: same path
28 &(?=(& -.q.one) ?=(& -.q.two)) :: both deltas
29 ==
30 [p.one [%& [*cart (weld q.q.q.one q.q.q.two)]]]
31 ::
33Examples
34--------
36 ~zod/try=> %/zak
37 ~zod/try=/zak> :ls %
38 mop
39 ~zod/try=/zak> (furl (fray %/mop) (foal %/mok 'hi'))
40 [ p=~.try
41 q
42 [ %.y
43 q
44 [ p=[p=0v0 q=0v0]
45 q=~[[p=/zak/mop q=[%del p=20]] [p=/zak/mok q=[%ins p=26.984]]]
46 ]
47 ]
48 ]