on master help sign in
thru 4f
9d44065Henry Ault
docs/system/hoon/library/src/2p/gate/cue.md+6−6
@@ -7,24 +7,24 @@ Produces a noun unpacked from atom `a`. The inverse of jam.
7Accepts
7Accepts
8-------
8-------
9
9
10−`a` is an [atom]().
10+`a` is an atom.
11
11
12Produces
12Produces
13--------
13--------
14
14
15−A [`++noun`]().
15+A `++noun`.
16
16
17Source
17Source
18------
18------
19
19
20− ++ cue :: unpack atom to noun
20+ ++ cue :: unpack
21 ~/ %cue
21 ~/ %cue
22− |= a=@
22+ |= a/@
23 ^- *
23 ^- *
24 =+ b=0
24 =+ b=0
25− =+ m=`(map ,@ ,*)`~
25+ =+ m=`(map @ *)`~
26 =< q
26 =< q
27− |- ^- [p=@ q=* r=_m]
27+ |- ^- {p/@ q/* r/(map @ *)}
28 ?: =(0 (cut 0 [b 1] a))
28 ?: =(0 (cut 0 [b 1] a))
29 =+ c=(rub +(b) a)
29 =+ c=(rub +(b) a)
30 [+(p.c) q.c (~(put by m) b q.c)]
30 [+(p.c) q.c (~(put by m) b q.c)]
docs/system/hoon/library/src/2p/gate/jam.md+4−4
@@ -7,7 +7,7 @@ Produces an atom unpacked from noun `a`. The inverse of cue.
7Accepts
7Accepts
8-------
8-------
9
9
10−`a` is a [noun]().
10+`a` is a noun.
11
11
12Produces
12Produces
13--------
13--------
@@ -19,12 +19,12 @@ Source
19
19
20 ++ jam :: pack
20 ++ jam :: pack
21 ~/ %jam
21 ~/ %jam
22− |= a=*
22+ |= a/*
23 ^- @
23 ^- @
24 =+ b=0
24 =+ b=0
25− =+ m=`(map ,* ,@)`~
25+ =+ m=`(map * @)`~
26 =< q
26 =< q
27− |- ^- [p=@ q=@ r=_m]
27+ |- ^- {p/@ q/@ r/(map * @)}
28 =+ c=(~(get by m) a)
28 =+ c=(~(get by m) a)
29 ?~ c
29 ?~ c
30 => .(m (~(put by m) a b))
30 => .(m (~(put by m) a b))
docs/system/hoon/library/src/2p/gate/mat.md+4−3
@@ -19,16 +19,17 @@ A cell of two atoms, `p` and `q`.
19Source
19Source
20------
20------
21
21
22− ++ mat :: length-encode
22+ ++ mat :: length-encode
23 ~/ %mat
23 ~/ %mat
24− |= a=@
24+ |= a/@
25− ^- [p=@ q=@]
25+ ^- {p/@ q/@}
26 ?: =(0 a)
26 ?: =(0 a)
27 [1 1]
27 [1 1]
28 =+ b=(met 0 a)
28 =+ b=(met 0 a)
29 =+ c=(met 0 b)
29 =+ c=(met 0 b)
30 :- (add (add c c) b)
30 :- (add (add c c) b)
31 (cat 0 (bex c) (mix (end 0 (dec c) b) (lsh 0 (dec c) a)))
31 (cat 0 (bex c) (mix (end 0 (dec c) b) (lsh 0 (dec c) a)))
32+ ::
32
33
33
34
34Examples
35Examples
docs/system/hoon/library/src/2p/gate/rub.md+2−2
@@ -24,8 +24,8 @@ Source
24
24
25 ++ rub :: length-decode
25 ++ rub :: length-decode
26 ~/ %rub
26 ~/ %rub
27− |= [a=@ b=@]
27+ |= {a/@ b/@}
28− ^- [p=@ q=@]
28+ ^- {p/@ q/@}
29 =+ ^= c
29 =+ ^= c
30 =+ [c=0 m=(met 0 b)]
30 =+ [c=0 m=(met 0 b)]
31 |- ?< (gth c m)
31 |- ?< (gth c m)
docs/system/hoon/library/src/4d/gate/last.md+4−5
@@ -2,15 +2,15 @@
2
2
3Farther trace
3Farther trace
4
4
5−Compares two line-column pairs, called [`++hair`]()s, `zyc` and `naz`, producing whichever
5+Compares two line-column pairs, called `++hair`s, `zyc` and `naz`, producing whichever
6is further along.
6is further along.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`naz` is a [hair]().
11+`naz` is a hair.
12
12
13−`zyc` is a [hair]().
13+`zyc` is a hair.
14
14
15Produces
15Produces
16--------
16--------
@@ -20,12 +20,11 @@ a `++hair`.
20Source
20Source
21------
21------
22
22
23− ++ last |= [zyc=hair naz=hair] :: farther trace
23+ ++ last |= {zyc/hair naz/hair} :: farther trace
24 ^- hair
24 ^- hair
25 ?: =(p.zyc p.naz)
25 ?: =(p.zyc p.naz)
26 ?:((gth q.zyc q.naz) zyc naz)
26 ?:((gth q.zyc q.naz) zyc naz)
27 ?:((gth p.zyc p.naz) zyc naz)
27 ?:((gth p.zyc p.naz) zyc naz)
28− ::
29
28
30
29
31Examples
30Examples
docs/system/hoon/library/src/4d/gate/lust.md+4−3
@@ -3,7 +3,7 @@
3
3
4Detect newline
4Detect newline
5
5
6−Advances the [`++hair`]() `naz` by a row if the [`++char`]() `weq` is a newline, or by a
6+Advances the `++hair` `naz` by a row if the `++char` `weq` is a newline, or by a
7column if `weq` is any other character.
7column if `weq` is any other character.
8
8
9Accepts
9Accepts
@@ -21,9 +21,10 @@ A hair.
21Source
21Source
22------
22------
23
23
24− ++ lust |= [weq=char naz=hair] :: detect newline
24+ ++ lust |= {weq/char naz/hair} :: detect newline
25 ^- hair
25 ^- hair
26− ?:(=(10 weq) [+(p.naz) 1] [p.naz +(q.naz)])
26+ ?:(=(`@`10 weq) [+(p.naz) 1] [p.naz +(q.naz)])
27+
27
28
28
29
29Examples
30Examples
docs/system/hoon/library/src/4e/gate/bend.md+14−14
@@ -2,8 +2,8 @@
2
2
3Conditional composer
3Conditional composer
4
4
5−Parsing composer: connects the [`++edge`]() `vex` with the subsequent [`++rule`]() `sab`
5+Parsing composer: connects the `++edge` `vex` with the subsequent `++rule` `sab`
6−as an optional suffix, using [gate]() `raq` to compose or reject its
6+as an optional suffix, using gate `raq` to compose or reject its
7result. If there is no suffix, or if the suffix fails to be composed
7result. If there is no suffix, or if the suffix fails to be composed
8with the current result, the current result is produced. Used to map a
8with the current result, the current result is produced. Used to map a
9group of rules to a specified output.
9group of rules to a specified output.
@@ -11,25 +11,25 @@ group of rules to a specified output.
11Accepts
11Accepts
12-------
12-------
13
13
14−`raq` is a [gate]().
14+`raq` is a gate.
15
15
16−`sab` is a [rule]().
16+`sab` is a rule.
17
17
18−`vex` is an [edge]().
18+`vex` is an edge.
19
19
20Produces
20Produces
21--------
21--------
22
22
23−A [`++rule`]().
23+A `++rule`.
24
24
25Source
25Source
26------
26------
27
27
28 ++ bend :: conditional comp
28 ++ bend :: conditional comp
29 ~/ %bend
29 ~/ %bend
30− |* raq=_|*([a=* b=*] [~ u=[a b]])
30+ |* raq/_|*({a/* b/*} [~ u=[a b]])
31 ~/ %fun
31 ~/ %fun
32− |* [vex=edge sab=_rule]
32+ |* {vex/edge sab/rule}
33 ?~ q.vex
33 ?~ q.vex
34 vex
34 vex
35 =+ yit=(sab q.u.q.vex)
35 =+ yit=(sab q.u.q.vex)
@@ -45,18 +45,18 @@ Source
45Examples
45Examples
46--------
46--------
47
47
48− ~zod/try=> (;~((bend |=([a=char b=char] ?.(=(a b) ~ (some +(a))))) prn prn) [1 1] "qs")
48+ ~zod/try=> (;~((bend |=([a/char b/char] ?.(=(a b) ~ (some +(a))))) prn prn) [1 1] "qs")
49 [p=[p=1 q=3] q=[~ u=[p=~~q q=[p=[p=1 q=2] q="s"]]]]
49 [p=[p=1 q=3] q=[~ u=[p=~~q q=[p=[p=1 q=2] q="s"]]]]
50− ~zod/try=> (;~((bend |=([a=char b=char] ?.(=(a b) ~ (some +(a))))) prn prn) [1 1] "qqq")
50+ ~zod/try=> (;~((bend |=([a/char b/char] ?.(=(a b) ~ (some +(a))))) prn prn) [1 1] "qqq")
51 [p=[p=1 q=3] q=[~ u=[p=~~r q=[p=[p=1 q=3] q="q"]]]]
51 [p=[p=1 q=3] q=[~ u=[p=~~r q=[p=[p=1 q=3] q="q"]]]]
52− ~zod/try=> (scan "aa" ;~((bend |=([a=char b=char] ?.(=(a b) ~ (some +(a))))) prn prn))
52+ ~zod/try=> (scan "aa" ;~((bend |=([a/char b/char] ?.(=(a b) ~ (some +(a))))) prn prn))
53 ~~b
53 ~~b
54− ~zod/try=> (scan "ba" ;~((bend |=([a=char b=char] ?.(=(a b) ~ (some +(a))))) prn prn))
54+ ~zod/try=> (scan "ba" ;~((bend |=([a/char b/char] ?.(=(a b) ~ (some +(a))))) prn prn))
55 ! {1 3}
55 ! {1 3}
56 ! exit
56 ! exit
57− ~zod/try=> `(unit ,@tas)`(scan "" ;~((bend) (easy ~) sym))
57+ ~zod/try=> `(unit @tas)`(scan "" ;~((bend) (easy ~) sym))
58 ~
58 ~
59− ~zod/try=> `(unit ,@tas)`(scan "sep" ;~((bend) (easy ~) sym))
59+ ~zod/try=> `(unit @tas)`(scan "sep" ;~((bend) (easy ~) sym))
60 [~ %sep]
60 [~ %sep]
61
61
62
62
docs/system/hoon/library/src/4e/gate/comp.md+9−8
@@ -2,14 +2,14 @@
2
2
3Arbitrary compose
3Arbitrary compose
4
4
5−Parsing composer: connects the [`++edge`]() `vex` with a following [`++rule`]() `sab`,
5+Parsing composer: connects the `++edge` `vex` with a following `++rule` `sab`,
6combining the contents of `vex` with the result of `sab` using a binary
6combining the contents of `vex` with the result of `sab` using a binary
7−[gate]() `raq`. Used to fold over the results of several `++rules`.
7+gate `raq`. Used to fold over the results of several `++rules`.
8
8
9Accepts
9Accepts
10-------
10-------
11
11
12−`raq` is a gate that accepts a cell of two [nouns](), `a` and `b`, and
12+`raq` is a gate that accepts a cell of two nouns, `a` and `b`, and
13produces a cell of two nouns.
13produces a cell of two nouns.
14
14
15`sab` is a rule.
15`sab` is a rule.
@@ -19,16 +19,17 @@ produces a cell of two nouns.
19Produces
19Produces
20--------
20--------
21
21
22−A [`++rule`]().
22+A `++rule`.
23
23
24Source
24Source
25------
25------
26
26
27 ++ comp
27 ++ comp
28 ~/ %comp
28 ~/ %comp
29− |* raq=_|*([a=* b=*] [a b]) :: arbitrary compose
29+ |* raq/_|*({a/* b/*} [a b]) :: arbitrary compose
30 ~/ %fun
30 ~/ %fun
31− |* [vex=edge sab=_rule]
31+ |* {vex/edge sab/rule}
32+ ~! +<
32 ?~ q.vex
33 ?~ q.vex
33 vex
34 vex
34 =+ yit=(sab q.u.q.vex)
35 =+ yit=(sab q.u.q.vex)
@@ -41,9 +42,9 @@ Source
41Examples
42Examples
42--------
43--------
43
44
44− ~zod/try=> (scan "123" ;~((comp |=([a=@u b=@u] (add a b))) dit dit dit))
45+ ~zod/try=> (scan "123" ;~((comp |=([a/@u b/@u] (add a b))) dit dit dit))
45 6
46 6
46− ~zod/try=> (scan "12" ;~((comp |=([a=@u b=@u] (add a b))) dit dit dit))
47+ ~zod/try=> (scan "12" ;~((comp |=([a/@u b/@u] (add a b))) dit dit dit))
47 ! {1 3}
48 ! {1 3}
48 ! exit
49 ! exit
49
50
docs/system/hoon/library/src/4e/gate/fail.md+3−3
@@ -2,13 +2,13 @@
2
2
3Never parse
3Never parse
4
4
5−Produces an [`++edge`]() at the same text position ([`++hair`]()) with a failing
5+Produces an `++edge` at the same text position (`++hair`) with a failing
6result (`q=~`).
6result (`q=~`).
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`tub` is a [`++nail`]().
11+`tub` is a `++nail`.
12
12
13Produces
13Produces
14--------
14--------
@@ -18,7 +18,7 @@ An `++edge`.
18Source
18Source
19------
19------
20
20
21− ++ fail |=(tub=nail [p=p.tub q=~]) :: never parse
21+ ++ fail |=(tub/nail [p=p.tub q=~]) :: never parse
22
22
23Examples
23Examples
24--------
24--------
docs/system/hoon/library/src/4e/gate/glue.md+3−3
@@ -2,7 +2,7 @@
2
2
3Skip delimiter
3Skip delimiter
4
4
5−Parsing composer: connects an [`++edge`]() `vex` with a following [`++rule`]() `sab` by
5+Parsing composer: connects an `++edge` `vex` with a following `++rule` `sab` by
6parsing the `++rule` `bus` (the delimiting symbol) and throwing out the
6parsing the `++rule` `bus` (the delimiting symbol) and throwing out the
7result.
7result.
8
8
@@ -25,9 +25,9 @@ Source
25
25
26 ++ glue :: add rule
26 ++ glue :: add rule
27 ~/ %glue
27 ~/ %glue
28− |* bus=_rule
28+ |* bus/rule
29 ~/ %fun
29 ~/ %fun
30− |* [vex=edge sab=_rule]
30+ |* {vex/edge sab/rule}
31 (plug vex ;~(pfix bus sab))
31 (plug vex ;~(pfix bus sab))
32 ::
32 ::
33
33
docs/system/hoon/library/src/4e/gate/less.md+4−4
@@ -2,8 +2,8 @@
2
2
3Parse unless
3Parse unless
4
4
5−Parsing composer: if an [`++edge`]() `vex` reflects a success, fail. Otherwise,
5+Parsing composer: if an `++edge` `vex` reflects a success, fail. Otherwise,
6−connect `vex` with the following [`++rule`]().
6+connect `vex` with the following `++rule`.
7
7
8Accepts
8Accepts
9-------
9-------
@@ -21,11 +21,11 @@ Source
21------
21------
22
22
23 ++ less :: no first and second
23 ++ less :: no first and second
24− |* [vex=edge sab=_rule]
24+ |* {vex/edge sab/rule}
25 ?~ q.vex
25 ?~ q.vex
26 =+ roq=(sab)
26 =+ roq=(sab)
27 [p=(last p.vex p.roq) q=q.roq]
27 [p=(last p.vex p.roq) q=q.roq]
28− vex(q ~)
28+ (fail +<.sab)
29 ::
29 ::
30
30
31Examples
31Examples
docs/system/hoon/library/src/4e/gate/pfix.md+3−4
@@ -2,13 +2,13 @@
2
2
3Discard first rule
3Discard first rule
4
4
5−Parsing composer: connects an [`++edge`]() `vex` with two subsequent [`++rule`]()s,
5+Parsing composer: connects an `++edge` `vex` with two subsequent `++rule`s,
6ignoring the result of the first and producing the result of the second.
6ignoring the result of the first and producing the result of the second.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`vex` is an [edge]().
11+`vex` is an edge.
12
12
13Produces
13Produces
14--------
14--------
@@ -20,8 +20,7 @@ Source
20
20
21 ++ pfix :: discard first rule
21 ++ pfix :: discard first rule
22 ~/ %pfix
22 ~/ %pfix
23− (comp |*([a=* b=*] b))
23+ (comp |*({a/* b/*} b))
24− ::
25
24
26Examples
25Examples
27--------
26--------
docs/system/hoon/library/src/4e/gate/plug.md+3−3
@@ -2,8 +2,8 @@
2
2
3Parse to tuple
3Parse to tuple
4
4
5−Parsing composer: connects an [`++edge`]() `vex` with a following [`++rule`]() `sab`, producing
5+Parsing composer: connects an `++edge` `vex` with a following `++rule` `sab`, producing
6−a cell of both the results. See also: the monad applicator [;\~]() for a
6+a cell of both the results. See also: the monad applicator ;\~ for a
7more detailed explanation.
7more detailed explanation.
8
8
9Accepts
9Accepts
@@ -23,7 +23,7 @@ Source
23
23
24 ++ plug :: first then second
24 ++ plug :: first then second
25 ~/ %plug
25 ~/ %plug
26− |* [vex=edge sab=_rule]
26+ |* {vex/edge sab/rule}
27 ?~ q.vex
27 ?~ q.vex
28 vex
28 vex
29 =+ yit=(sab q.u.q.vex)
29 =+ yit=(sab q.u.q.vex)
docs/system/hoon/library/src/4e/gate/pose.md+6−4
@@ -3,14 +3,14 @@
3Parse options
3Parse options
4
4
5Parsing composer: if `vex` reflects a failure, connect it with the
5Parsing composer: if `vex` reflects a failure, connect it with the
6−following rule `sab`. See also: the monad applicator [;\~]()
6+following rule `sab`. See also: the monad applicator ;\~
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`sab` is a [`++rule`]().
11+`sab` is a `++rule`.
12
12
13−`vex` is an [`++edge`]().
13+`vex` is an `++edge`.
14
14
15Produces
15Produces
16--------
16--------
@@ -22,11 +22,13 @@ Source
22
22
23 ++ pose :: first or second
23 ++ pose :: first or second
24 ~/ %pose
24 ~/ %pose
25− |* [vex=edge sab=_rule]
25+ |* {vex/edge sab/rule}
26 ?~ q.vex
26 ?~ q.vex
27 =+ roq=(sab)
27 =+ roq=(sab)
28 [p=(last p.vex p.roq) q=q.roq]
28 [p=(last p.vex p.roq) q=q.roq]
29 vex
29 vex
30+ ::
31+
30
32
31Examples
33Examples
32--------
34--------
docs/system/hoon/library/src/4e/gate/sfix.md+3−2
@@ -2,7 +2,7 @@
2
2
3Discard second rule
3Discard second rule
4
4
5−Parsing composer: connects [`++edge`]()s `vex` with two subsequent [`++rule`]()s returning the
5+Parsing composer: connects `++edge`s `vex` with two subsequent `++rule`s returning the
6result of the first and discarding the result of the second.
6result of the first and discarding the result of the second.
7
7
8Accepts
8Accepts
@@ -22,7 +22,8 @@ Source
22
22
23 ++ sfix :: discard second rule
23 ++ sfix :: discard second rule
24 ~/ %sfix
24 ~/ %sfix
25− (comp |*([a=* b=*] a))
25+ (comp |*({a/* b/*} a))
26+
26
27
27Examples
28Examples
28--------
29--------
docs/system/hoon/library/src/4e/gate/simu.md+3−3
@@ -2,8 +2,8 @@
2
2
3First and second
3First and second
4
4
5−Parsing composer: if an [`++edge`]() `vex` reflects a failure, fail. Otherwise,
5+Parsing composer: if an `++edge` `vex` reflects a failure, fail. Otherwise,
6−connect `vex` with the following [`++rule`]().
6+connect `vex` with the following `++rule`.
7
7
8Accepts
8Accepts
9-------
9-------
@@ -21,7 +21,7 @@ Source
21------
21------
22
22
23 ++ simu :: first and second
23 ++ simu :: first and second
24− |* [vex=edge sab=_rule]
24+ |* {vex/edge sab/rule}
25 ?~ q.vex
25 ?~ q.vex
26 vex
26 vex
27 =+ roq=(sab)
27 =+ roq=(sab)
docs/system/hoon/library/src/4f/gate/bass.md+9−7
@@ -1,31 +1,33 @@
1### `++bass`
1### `++bass`
2
2
3−Parser modifier: [LSB](http://en.wikipedia.org/wiki/Least_significant_bit)
3+Parser modifier: LSB
4−ordered [`++list`]() as atom of a [`++base`]().
4+ordered `++list` as atom of a `++base`.
5
5
6Accepts
6Accepts
7-------
7-------
8
8
9`wuc` is an atom.
9`wuc` is an atom.
10
10
11−`tyd` is a [`++rule`]().
11+`tyd` is a `++rule`.
12
12
13Produces
13Produces
14--------
14--------
15
15
16−A [`++rule`]().
16+A `++rule`.
17
17
18Source
18Source
19------
19------
20
20
21 ++ bass
21 ++ bass
22− |* [wuc=@ tyd=_rule]
22+ |* {wuc/@ tyd/rule}
23 %+ cook
23 %+ cook
24− |= waq=(list ,@)
24+ |= waq/(list @)
25 %+ roll
25 %+ roll
26 waq
26 waq
27− =|([p=@ q=@] |.((add p (mul wuc q))))
27+ =|({p/@ q/@} |.((add p (mul wuc q))))
28 tyd
28 tyd
29+ ::
30+
29
31
30Examples
32Examples
31--------
33--------
docs/system/hoon/library/src/4f/gate/boss.md+9−7
@@ -1,32 +1,34 @@
1
1
2### `++boss`
2### `++boss`
3
3
4−Parser modifier: [LSB](http://en.wikipedia.org/wiki/Least_significant_bit)
4+Parser modifier: LSB
5+
5−ordered [`++list`]() as atom of a [`++base`]().
6+Ordered `++list` as atom of a `++base`.
6
7
7Accepts
8Accepts
8-------
9-------
9
10
10`wuc` is an atom.
11`wuc` is an atom.
11
12
12−`tyd` is a [`++rule`]().
13+`tyd` is a `++rule`.
13
14
14Produces
15Produces
15--------
16--------
16
17
17−A [`++rule`]().
18+A `++rule`.
18
19
19Source
20Source
20------
21------
21
22
22 ++ boss
23 ++ boss
23− |* [wuc=@ tyd=_rule]
24+ |* {wuc/@ tyd/rule}
24 %+ cook
25 %+ cook
25− |= waq=(list ,@)
26+ |= waq/(list @)
26 %+ reel
27 %+ reel
27 waq
28 waq
28− =|([p=@ q=@] |.((add p (mul wuc q))))
29+ =|({p/@ q/@} |.((add p (mul wuc q))))
29 tyd
30 tyd
31+ ::
30
32
31Examples
33Examples
32--------
34--------
docs/system/hoon/library/src/4f/gate/cold.md+6−7
@@ -2,34 +2,33 @@
2
2
3Replace with constant
3Replace with constant
4
4
5−Parser modifier. Accepts a [`++rule`]() `sef` and produces a parser that
5+Parser modifier. Accepts a `++rule` `sef` and produces a parser that
6produces a constant `cus`, assuming `sef` is successful.
6produces a constant `cus`, assuming `sef` is successful.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`cus` is a constant [noun]().
11+`cus` is a constant noun.
12
12
13`sef` is a `++rule`.
13`sef` is a `++rule`.
14
14
15Produces
15Produces
16--------
16--------
17
17
18−An [`++edge`]().
18+An `++edge`.
19
19
20Source
20Source
21------
21------
22
22
23− ++ cold :: replace w/ constant
23+ ++ cold :: replace w+ constant
24 ~/ %cold
24 ~/ %cold
25− |* [cus=* sef=_rule]
25+ |* {cus/* sef/rule}
26 ~/ %fun
26 ~/ %fun
27− |= tub=nail
27+ |= tub/nail
28 =+ vex=(sef tub)
28 =+ vex=(sef tub)
29 ?~ q.vex
29 ?~ q.vex
30 vex
30 vex
31 [p=p.vex q=[~ u=[p=cus q=q.u.q.vex]]]
31 [p=p.vex q=[~ u=[p=cus q=q.u.q.vex]]]
32− ::
33
32
34Examples
33Examples
35--------
34--------
docs/system/hoon/library/src/4f/gate/cook.md+6−6
@@ -3,28 +3,28 @@
3Apply gate
3Apply gate
4
4
5Parser modifier. Produces a parser that takes a (successful) result of a
5Parser modifier. Produces a parser that takes a (successful) result of a
6−[`++rule`]() `sef` and slams it through `poq`.
6+`++rule` `sef` and slams it through `poq`.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`poq` is a [gate]().
11+`poq` is a gate.
12
12
13−`sef` is a [`++rule`]().
13+`sef` is a `++rule`.
14
14
15Produces
15Produces
16--------
16--------
17
17
18−An [`++rule`]().
18+An `++rule`.
19
19
20Source
20Source
21------
21------
22
22
23 ++ cook :: apply gate
23 ++ cook :: apply gate
24 ~/ %cook
24 ~/ %cook
25− |* [poq=_,* sef=_rule]
25+ |* {poq/$-(* *) sef/rule}
26 ~/ %fun
26 ~/ %fun
27− |= tub=nail
27+ |= tub/nail
28 =+ vex=(sef tub)
28 =+ vex=(sef tub)
29 ?~ q.vex
29 ?~ q.vex
30 vex
30 vex
docs/system/hoon/library/src/4f/gate/easy.md+2−2
@@ -2,7 +2,7 @@
2
2
3Always parse
3Always parse
4
4
5−Parser generator. Produces a parser that succeeds with given [noun]() `huf`
5+Parser generator. Produces a parser that succeeds with given noun `huf`
6without consuming any text.
6without consuming any text.
7
7
8Accepts
8Accepts
@@ -13,7 +13,7 @@ Accepts
13Produces
13Produces
14--------
14--------
15
15
16−A [`++rule`]().
16+A `++rule`.
17
17
18Source
18Source
19------
19------
docs/system/hoon/library/src/4f/gate/full.md+2−2
@@ -2,13 +2,13 @@
2
2
3Parse to end
3Parse to end
4
4
5−Parser modifier. Accepts a [`++rule`]() `sef`, and produces a parser that succeeds only
5+Parser modifier. Accepts a `++rule` `sef`, and produces a parser that succeeds only
6when the of `tub` is fully consumed using `sef`.
6when the of `tub` is fully consumed using `sef`.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`sef` is a [`++rule`]().
11+`sef` is a `++rule`.
12
12
13Produces
13Produces
14--------
14--------
docs/system/hoon/library/src/4f/gate/funk.md+4−5
@@ -2,14 +2,14 @@
2
2
3Add to tape
3Add to tape
4
4
5−Parser modifier: prepend text to [`++tape`]() before applying parser.
5+Parser modifier: prepend text to `++tape` before applying parser.
6
6
7Accepts
7Accepts
8-------
8-------
9
9
10`pre` is a `++tape`
10`pre` is a `++tape`
11
11
12−`sef` is a [`++rule`]()
12+`sef` is a `++rule`
13
13
14Produces
14Produces
15--------
15--------
@@ -20,10 +20,9 @@ Source
20------
20------
21
21
22 ++ funk :: add to tape first
22 ++ funk :: add to tape first
23− |* [pre=tape sef=_rule]
23+ |* {pre/tape sef/rule}
24− |= tub=nail
24+ |= tub/nail
25 (sef p.tub (weld pre q.tub))
25 (sef p.tub (weld pre q.tub))
26− ::
27
26
28Examples
27Examples
29--------
28--------
docs/system/hoon/library/src/4f/gate/here.md+6−6
@@ -2,16 +2,16 @@
2
2
3Place-based apply
3Place-based apply
4
4
5−Parser modifier. Similar to [`++cook`]() in that it produces a parser that takes a
5+Parser modifier. Similar to `++cook` in that it produces a parser that takes a
6(successful) result of `sef` and slams it through `hez`. `hez` accepts a
6(successful) result of `sef` and slams it through `hez`. `hez` accepts a
7−[`++pint`]() `a` and a [noun]() `b`, which is what the parser parsed.
7+`++pint` `a` and a noun `b`, which is what the parser parsed.
8
8
9Accepts
9Accepts
10-------
10-------
11
11
12−`hez` is a [gate]().
12+`hez` is a gate.
13
13
14−`sef` is a [`++rule`]()
14+`sef` is a `++rule`
15
15
16Produces
16Produces
17--------
17--------
@@ -23,9 +23,9 @@ Source
23
23
24 ++ here :: place-based apply
24 ++ here :: place-based apply
25 ~/ %here
25 ~/ %here
26− |* [hez=_|=([a=pint b=*] [a b]) sef=_rule]
26+ |* {hez/_|=({a/pint b/*} [a b]) sef/rule}
27 ~/ %fun
27 ~/ %fun
28− |= tub=nail
28+ |= tub/nail
29 =+ vex=(sef tub)
29 =+ vex=(sef tub)
30 ?~ q.vex
30 ?~ q.vex
31 vex
31 vex
docs/system/hoon/library/src/4f/gate/ifix.md+7−3
@@ -2,7 +2,7 @@
2
2
3Infix
3Infix
4
4
5−Parser modifier: surround with pair of [`++rule`]()s, the output of which is
5+Parser modifier: surround with pair of `++rule`s, the output of which is
6discarded.
6discarded.
7
7
8Accepts
8Accepts
@@ -21,8 +21,12 @@ Source
21------
21------
22
22
23 ++ ifix
23 ++ ifix
24− |* [fel=[p=_rule q=_rule] hof=_rule]
24+ |* {fel/{rule rule} hof/rule}
25+ ~! +<
26+ ~! +<:-.fel
27+ ~! +<:+.fel
25− ;~(pfix p.fel ;~(sfix hof q.fel))
28+ ;~(pfix -.fel ;~(sfix hof +.fel))
29+ ::
26
30
27Examples
31Examples
28--------
32--------
docs/system/hoon/library/src/4f/gate/jest.md+7−7
@@ -7,24 +7,24 @@ Match and consume a cord.
7Accepts
7Accepts
8-------
8-------
9
9
10−`daf` is a [`@t`]().
10+`daf` is a `@t`.
11
11
12Produces
12Produces
13--------
13--------
14
14
15−An [`++edge`]().
15+An `++edge`.
16
16
17Source
17Source
18------
18------
19
19
20 ++ jest :: match a cord
20 ++ jest :: match a cord
21− |= daf=@t
21+ |= daf/@t
22− |= tub=nail
22+ |= tub/nail
23 =+ fad=daf
23 =+ fad=daf
24− |- ^- (like ,@t)
24+ |- ^- (like @t)
25− ?: =(0 daf)
25+ ?: =(`@`0 daf)
26 [p=p.tub q=[~ u=[p=fad q=tub]]]
26 [p=p.tub q=[~ u=[p=fad q=tub]]]
27− ?: |(?=(~ q.tub) !=((end 3 1 daf) i.q.tub))
27+ ?: |(?=($~ q.tub) !=((end 3 1 daf) i.q.tub))
28 (fail tub)
28 (fail tub)
29 $(p.tub (lust i.q.tub p.tub), q.tub t.q.tub, daf (rsh 3 1 daf))
29 $(p.tub (lust i.q.tub p.tub), q.tub t.q.tub, daf (rsh 3 1 daf))
30 ::
30 ::
docs/system/hoon/library/src/4f/gate/just.md+4−4
@@ -7,21 +7,21 @@ Match and consume a single character.
7Accepts
7Accepts
8-------
8-------
9
9
10−`daf` is a [`++char`]()
10+`daf` is a `++char`
11
11
12Produces
12Produces
13--------
13--------
14
14
15−A [`++rule`]().
15+A `++rule`.
16
16
17Source
17Source
18------
18------
19
19
20 ++ just :: XX redundant, jest
20 ++ just :: XX redundant, jest
21 ~/ %just :: match a char
21 ~/ %just :: match a char
22− |= daf=char
22+ |= daf/char
23 ~/ %fun
23 ~/ %fun
24− |= tub=nail
24+ |= tub/nail
25 ^- (like char)
25 ^- (like char)
26 ?~ q.tub
26 ?~ q.tub
27 (fail tub)
27 (fail tub)
docs/system/hoon/library/src/4f/gate/knee.md+5−5
@@ -10,20 +10,20 @@ Accepts
10
10
11`gar` is a noun.
11`gar` is a noun.
12
12
13−`sef` is a [gate]() that accepts a [`++rule`]()
13+`sef` is a gate that accepts a `++rule`
14
14
15Produces
15Produces
16--------
16--------
17
17
18−A [`++rule`]().
18+A `++rule`.
19
19
20Source
20Source
21------
21------
22
22
23 ++ knee :: callbacks
23 ++ knee :: callbacks
24− |* [gar=* sef=_|.(rule)]
24+ |* {gar/* sef/_|.(*rule)}
25− |= tub=nail
25+ |= tub/nail
26− ^- (like ,_gar)
26+ ^- (like _gar)
27 ((sef) tub)
27 ((sef) tub)
28 ::
28 ::
29
29
docs/system/hoon/library/src/4f/gate/mask.md+5−5
@@ -8,25 +8,25 @@ characters.
8Accepts
8Accepts
9-------
9-------
10
10
11−`bud` is a list of [`++char`]()
11+`bud` is a list of `++char`
12
12
13Produces
13Produces
14--------
14--------
15
15
16−A [`++rule`]().
16+A `++rule`.
17
17
18Source
18Source
19------
19------
20
20
21 ++ mask :: match char in set
21 ++ mask :: match char in set
22 ~/ %mask
22 ~/ %mask
23− |= bud=(list char)
23+ |= bud/(list char)
24 ~/ %fun
24 ~/ %fun
25− |= tub=nail
25+ |= tub/nail
26 ^- (like char)
26 ^- (like char)
27 ?~ q.tub
27 ?~ q.tub
28 (fail tub)
28 (fail tub)
29− ?. (lien bud |=(a=char =(i.q.tub a)))
29+ ?. (lien bud |=(a/char =(i.q.tub a)))
30 (fail tub)
30 (fail tub)
31 (next tub)
31 (next tub)
32 ::
32 ::
docs/system/hoon/library/src/4f/gate/more.md+3−2
@@ -2,7 +2,7 @@
2
2
3Parse list with delimiter
3Parse list with delimiter
4
4
5−Parser modifier: Parse a list of matches using a delimiter [`++rule`]().
5+Parser modifier: Parse a list of matches using a delimiter `++rule`.
6
6
7Accepts
7Accepts
8-------
8-------
@@ -20,8 +20,9 @@ Source
20------
20------
21
21
22 ++ more
22 ++ more
23− |* [bus=_rule fel=_rule]
23+ |* {bus/rule fel/rule}
24 ;~(pose (most bus fel) (easy ~))
24 ;~(pose (most bus fel) (easy ~))
25+ ::
25
26
26Examples
27Examples
27--------
28--------
docs/system/hoon/library/src/4f/gate/most.md+3−2
@@ -2,7 +2,7 @@
2
2
3Parse list of at least one match
3Parse list of at least one match
4
4
5−Parser modifier: parse a [`++list`]() of at least one match using a delimiter [`++rule`]().
5+Parser modifier: parse a `++list` of at least one match using a delimiter `++rule`.
6
6
7Accepts
7Accepts
8-------
8-------
@@ -20,8 +20,9 @@ Source
20------
20------
21
21
22 ++ most
22 ++ most
23− |* [bus=_rule fel=_rule]
23+ |* {bus/rule fel/rule}
24 ;~(plug fel (star ;~(pfix bus fel)))
24 ;~(plug fel (star ;~(pfix bus fel)))
25+ ::
25
26
26Examples
27Examples
27--------
28--------
docs/system/hoon/library/src/4f/gate/next.md+3−3
@@ -7,18 +7,18 @@ Consume any character, producing it as a result.
7Accepts
7Accepts
8-------
8-------
9
9
10−`tub` is a [`++nail`]()
10+`tub` is a `++nail`
11
11
12Produces
12Produces
13--------
13--------
14
14
15−An [`++edge`]().
15+An `++edge`.
16
16
17Source
17Source
18------
18------
19
19
20 ++ next :: consume a char
20 ++ next :: consume a char
21− |= tub=nail
21+ |= tub/nail
22 ^- (like char)
22 ^- (like char)
23 ?~ q.tub
23 ?~ q.tub
24 (fail tub)
24 (fail tub)
docs/system/hoon/library/src/4f/gate/plus.md+4−3
@@ -3,12 +3,12 @@
3
3
4List of at least one match.
4List of at least one match.
5
5
6−Parser modifier: parse [`++list`]() of at least one match.
6+Parser modifier: parse `++list` of at least one match.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`fel` is a [`++rule`]().
11+`fel` is a `++rule`.
12
12
13Produces
13Produces
14--------
14--------
@@ -18,7 +18,8 @@ A `++rule`.
18Source
18Source
19------
19------
20
20
21− ++ plus |*(fel=_rule ;~(plug fel (star fel)))
21+ ++ plus |*(fel/rule ;~(plug fel (star fel)))
22+
22
23
23Examples
24Examples
24--------
25--------
docs/system/hoon/library/src/4f/gate/sear.md+7−7
@@ -2,25 +2,24 @@
2
2
3Conditional `++cook`
3Conditional `++cook`
4
4
5−Conditional [`++cook`](). Slams the result through a gate that produces
5+Conditional `++cook`. Slams the result through a gate that produces
6a unit; if that unit is empty, fail.
6a unit; if that unit is empty, fail.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`tub` is a [`++nail`](/doc/hoon/library/1#++nail)
11+`tub` is a `++nail`.
12−
13Produces
12Produces
14--------
13--------
15
14
16−A [`++rule`]().
15+A `++rule`.
17
16
18Source
17Source
19------
18------
20
19
21 ++ sear :: conditional cook
20 ++ sear :: conditional cook
22− |* [pyq=_|=(* *(unit)) sef=_rule]
21+ |* {pyq/$-(* (unit)) sef/rule}
23− |= tub=nail
22+ |= tub/nail
24 =+ vex=(sef tub)
23 =+ vex=(sef tub)
25 ?~ q.vex
24 ?~ q.vex
26 vex
25 vex
@@ -30,10 +29,11 @@ Source
30 [p=p.vex q=[~ u=[p=u.gey q=q.u.q.vex]]]
29 [p=p.vex q=[~ u=[p=u.gey q=q.u.q.vex]]]
31 ::
30 ::
32
31
32+
33Examples
33Examples
34--------
34--------
35
35
36− ~zod/try=> ((sear |=(a=* ?@(a (some a) ~)) (just `a`)) [[1 1] "abc"])
36+ ~zod/try=> ((sear |=(a/* ?@(a (some a) ~)) (just `a`)) [[1 1] "abc"])
37 [p=[p=1 q=2] q=[~ u=[p=97 q=[p=[p=1 q=2] q="bc"]]]]
37 [p=[p=1 q=2] q=[~ u=[p=97 q=[p=[p=1 q=2] q="bc"]]]]
38 ~zod/try=> ((sear |=(* ~) (just 'a')) [[1 1] "abc"])
38 ~zod/try=> ((sear |=(* ~) (just 'a')) [[1 1] "abc"])
39 [p=[p=1 q=2] q=~]
39 [p=[p=1 q=2] q=~]
docs/system/hoon/library/src/4f/gate/shim.md+4−4
@@ -2,7 +2,7 @@
2
2
3Char in range
3Char in range
4
4
5−Match characters ([`++char`]()) within a range.
5+Match characters (`++char`) within a range.
6
6
7Accepts
7Accepts
8-------
8-------
@@ -14,16 +14,16 @@ Accepts
14Produces
14Produces
15--------
15--------
16
16
17−A [`++rule`]().
17+A `++rule`.
18
18
19Source
19Source
20------
20------
21
21
22 ++ shim :: match char in range
22 ++ shim :: match char in range
23 ~/ %shim
23 ~/ %shim
24− |= [les=@ mos=@]
24+ |= {les/@ mos/@}
25 ~/ %fun
25 ~/ %fun
26− |= tub=nail
26+ |= tub/nail
27 ^- (like char)
27 ^- (like char)
28 ?~ q.tub
28 ?~ q.tub
29 (fail tub)
29 (fail tub)
docs/system/hoon/library/src/4f/gate/slug.md+7−5
@@ -2,13 +2,13 @@
2
2
3Use gate to parse delimited list
3Use gate to parse delimited list
4
4
5−Parser modifier: By composing with a [gate](), parse a delimited [`++list`]() of
5+Parser modifier: By composing with a gate, parse a delimited `++list` of
6matches.
6matches.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`bus` is a [`++rule`]().
11+`bus` is a `++rule`.
12
12
13`fel` is a `++rule`.
13`fel` is a `++rule`.
14
14
@@ -21,16 +21,18 @@ Source
21------
21------
22
22
23 ++ slug
23 ++ slug
24− |* raq=_|*([a=* b=*] [a b])
24+ |* raq/_|*({a/* b/*} [a b])
25− |* [bus=_rule fel=_rule]
25+ |* {bus/rule fel/rule}
26 ;~((comp raq) fel (stir +<+.raq raq ;~(pfix bus fel)))
26 ;~((comp raq) fel (stir +<+.raq raq ;~(pfix bus fel)))
27+ ::
28+
27
29
28Examples
30Examples
29--------
31--------
30
32
31 ~zod/try=> (scan "20+5+110" ((slug add) lus dem))
33 ~zod/try=> (scan "20+5+110" ((slug add) lus dem))
32 135
34 135
33− ~zod/try=> `@t`(scan "a b c" ((slug |=(a=[@ @t] (cat 3 a))) ace alp))
35+ ~zod/try=> `@t`(scan "a b c" ((slug |=(a/[@ @t] (cat 3 a))) ace alp))
34 'abc'
36 'abc'
35
37
36
38
docs/system/hoon/library/src/4f/gate/stag.md+3−3
@@ -14,16 +14,16 @@ Accepts
14Produces
14Produces
15--------
15--------
16
16
17−A [`++rule`]().
17+A `++rule`.
18
18
19Source
19Source
20------
20------
21
21
22 ++ stag :: add a label
22 ++ stag :: add a label
23 ~/ %stag
23 ~/ %stag
24− |* [gob=* sef=_rule]
24+ |* {gob/* sef/rule}
25 ~/ %fun
25 ~/ %fun
26− |= tub=nail
26+ |= tub/nail
27 =+ vex=(sef tub)
27 =+ vex=(sef tub)
28 ?~ q.vex
28 ?~ q.vex
29 vex
29 vex
docs/system/hoon/library/src/4f/gate/star.md+4−4
@@ -2,19 +2,19 @@
2
2
3List of matches
3List of matches
4
4
5−Parser modifier: parse [`++list`]() of matches.
5+Parser modifier: parse `++list` of matches.
6
6
7Accepts
7Accepts
8-------
8-------
9
9
10−`fel` is a [`++rule`]().
10+`fel` is a `++rule`.
11
11
12Produces
12Produces
13--------
13--------
14
14
15 ++ star :: 0 or more times
15 ++ star :: 0 or more times
16− |* fel=_rule
16+ |* fel/rule
17− (stir `(list ,_(wonk *fel))`~ |*([a=* b=*] [a b]) fel)
17+ (stir `(list _(wonk *fel))`~ |*({a/* b/*} [a b]) fel)
18
18
19Examples
19Examples
20--------
20--------
docs/system/hoon/library/src/4f/gate/stet.md+1−1
@@ -18,7 +18,7 @@ Source
18------
18------
19
19
20 ++ stet
20 ++ stet
21− |* leh=(list ,[?(@ [@ @]) _rule])
21+ |* leh/(list {?(@ {@ @}) rule})
22 |-
22 |-
23 ?~ leh
23 ?~ leh
24 ~
24 ~
docs/system/hoon/library/src/4f/gate/stew.md+8−6
@@ -4,14 +4,14 @@ Switch by first
4
4
5 ++ stew :: switch by first char
5 ++ stew :: switch by first char
6 ~/ %stew
6 ~/ %stew
7− |* leh=(list ,[p=?(@ [@ @]) q=_rule]) :: char/range keys
7+ |* leh/(list {p/?(@ {@ @}) q/rule}) :: char+range keys
8 =+ ^= wor :: range complete lth
8 =+ ^= wor :: range complete lth
9− |= [ort=?(@ [@ @]) wan=?(@ [@ @])]
9+ |= {ort/?(@ {@ @}) wan/?(@ {@ @})}
10 ?@ ort
10 ?@ ort
11 ?@(wan (lth ort wan) (lth ort -.wan))
11 ?@(wan (lth ort wan) (lth ort -.wan))
12 ?@(wan (lth +.ort wan) (lth +.ort -.wan))
12 ?@(wan (lth +.ort wan) (lth +.ort -.wan))
13 =+ ^= hel :: build parser map
13 =+ ^= hel :: build parser map
14− =+ hel=`(tree $_(?>(?=(^ leh) i.leh)))`~
14+ =+ hel=`(tree _?>(?=(^ leh) i.leh))`~
15 |- ^+ hel
15 |- ^+ hel
16 ?~ leh
16 ?~ leh
17 ~
17 ~
@@ -31,7 +31,7 @@ Switch by first
31 [n.yal l.yal nuc]
31 [n.yal l.yal nuc]
32 [n.nuc [n.yal l.yal l.nuc] r.nuc]
32 [n.nuc [n.yal l.yal l.nuc] r.nuc]
33 ~% %fun ..^$ ~
33 ~% %fun ..^$ ~
34− |= tub=nail
34+ |= tub/nail
35 ?~ q.tub
35 ?~ q.tub
36 (fail tub)
36 (fail tub)
37 |-
37 |-
@@ -47,8 +47,10 @@ Switch by first
47 $(hel r.hel)
47 $(hel r.hel)
48 ::
48 ::
49
49
50+
51+
50−Parser generator. From an associative [`++list`]() of characters or character
52+Parser generator. From an associative `++list` of characters or character
51−ranges to [`++rule`]()s, construct a [`++map`](), and parse [`++tape`]()s only
53+ranges to `++rule`s, construct a `++map`, and parse `++tape`s only
52with `++rules` associated with a range that the `++tape`'s first character falls in.
54with `++rules` associated with a range that the `++tape`'s first character falls in.
53
55
54
56
docs/system/hoon/library/src/4f/gate/stir.md+19−12
@@ -2,7 +2,7 @@
2
2
3Parse repeatedly
3Parse repeatedly
4
4
5−Parse with [`++rule`]() as many times as possible, and fold over results with a
5+Parse with `++rule` as many times as possible, and fold over results with a
6binary gate.
6binary gate.
7
7
8Accepts
8Accepts
@@ -22,19 +22,26 @@ A rule.
22Source
22Source
23------
23------
24
24
25−++ stir :: parse repeatedly
25+ ++ stun :: parse several times
26− ~/ %stir
26+ |* {lig/{@ @} fel/rule}
27− |* [rud=* raq=_|*([a=* b=*] [a b]) fel=_rule]
28− ~/ %fun
29− |= tub=nail
27+ |= tub/nail
30− ^- (like ,_rud)
28+ ^- (like (list _(wonk (fel))))
29+ ?: =(0 +.lig)
30+ [p.tub [~ ~ tub]]
31 =+ vex=(fel tub)
31 =+ vex=(fel tub)
32 ?~ q.vex
32 ?~ q.vex
33+ ?: =(0 -.lig)
33− [p.vex [~ rud tub]]
34+ [p.vex [~ ~ tub]]
35+ vex
36+ =+ ^= wag %= $
37+ -.lig ?:(=(0 -.lig) 0 (dec -.lig))
38+ +.lig ?:(=(0 +.lig) 0 (dec +.lig))
34− =+ wag=$(tub q.u.q.vex)
39+ tub q.u.q.vex
40+ ==
35− ?> ?=(^ q.wag)
41+ ?~ q.wag
42+ wag
36− [(last p.vex p.wag) [~ (raq p.u.q.vex p.u.q.wag) q.u.q.wag]]
43+ [p.wag [~ [p.u.q.vex p.u.q.wag] q.u.q.wag]]
37− ::
44+
38
45
39Examples
46Examples
40--------
47--------
docs/system/hoon/library/src/4f/gate/stun.md+9−9
@@ -9,30 +9,30 @@ Accepts
9
9
10`[les=@ mos=@]` is a cell of atoms indicating the bounds.
10`[les=@ mos=@]` is a cell of atoms indicating the bounds.
11
11
12−`fel` is a [`++rule`]().
12+`fel` is a `++rule`.
13
13
14Produces
14Produces
15--------
15--------
16
16
17−A [`++rule`]().
17+A `++rule`.
18
18
19Source
19Source
20------
20------
21
21
22 ++ stun :: parse several times
22 ++ stun :: parse several times
23− |* [[les=@ mos=@] fel=_rule]
23+ |* {lig/{@ @} fel/rule}
24− |= tub=nail
24+ |= tub/nail
25− ^- (like (list ,_(wonk (fel))))
25+ ^- (like (list _(wonk (fel))))
26− ?: =(0 mos)
26+ ?: =(0 +.lig)
27 [p.tub [~ ~ tub]]
27 [p.tub [~ ~ tub]]
28 =+ vex=(fel tub)
28 =+ vex=(fel tub)
29 ?~ q.vex
29 ?~ q.vex
30− ?: =(0 les)
30+ ?: =(0 -.lig)
31 [p.vex [~ ~ tub]]
31 [p.vex [~ ~ tub]]
32 vex
32 vex
33 =+ ^= wag %= $
33 =+ ^= wag %= $
34− les ?:(=(0 les) 0 (dec les))
34+ -.lig ?:(=(0 -.lig) 0 (dec -.lig))
35− mos ?:(=(0 mos) 0 (dec mos))
35+ +.lig ?:(=(0 +.lig) 0 (dec +.lig))
36 tub q.u.q.vex
36 tub q.u.q.vex
37 ==
37 ==
38 ?~ q.wag
38 ?~ q.wag