on master help sign in
thru 4L
ccd1a08Henry Ault
docs/system/hoon/library/src/4k/core/co.md+140−214
@@ -2,7 +2,7 @@
2
2
3Literal rendering engine
3Literal rendering engine
4
4
5−A [door]() that contains arms that operate on the sample coin `lot`.
5+A door that contains arms that operate on the sample coin `lot`.
6
6
7Accepts
7Accepts
8-------
8-------
@@ -10,27 +10,24 @@ Accepts
10Produces
10Produces
11--------
11--------
12
12
13−`lot` is a [`++coin`]().
13+`lot` is a `++coin`.
14
14
15Source
15Source
16------
16------
17
17
18− ++ co
18+ ++ co !.
19+ ~% %co ..co ~
19− =< |_ lot=coin
20+ =< |_ lot/coin
21+
20
22
21Examples
23Examples
22--------
24--------
23
25
24− ~zod/try=> ~(. co many/~[`ta/'mo' `ud/5])
26+ ~zod/try=> < 3.nta
25− < 3.dhd
26− [ [ %many
27+ { lot/{$many {$~ $ta @t} {$~ $ud @ud} $~}
27− [%~ %ta @t]
28+ <10.cfg 4.jjn {rep/"" <402.arm 110.jyx 1.ztu $151>}>
28− [%~ %ud @ud]
29+ }
29− %~
30− ]
31− <10.utz 3.zid [rex="" <414.hmb 100.xkc 1.ypj %164>]>
32− ]
33− >
30+ >
34
31
35------------------------------------------------------------------------
32------------------------------------------------------------------------
36
33
@@ -38,7 +35,7 @@ Examples
38
35
39Prepend & render as tape
36Prepend & render as tape
40
37
41−Renders a coin `lot` as a [tape]() prepended to the sample tape `rom`.
38+Renders a coin `lot` as a tape prepended to the sample tape `rom`.
42
39
43Accepts
40Accepts
44-------
41-------
@@ -46,14 +43,14 @@ Accepts
46Produces
43Produces
47--------
44--------
48
45
49−`rom` is a [`pe`]()
46+`rom` is a `pe`
50
47
51−`lot` is a [`++coin`]().
48+`lot` is a `++coin`.
52
49
53Source
50Source
54------
51------
55
52
56− ++ rear |=(rom=tape =>(.(rex rom) rend))
53+ ++ rear |=(rom/tape =>(.(rex rom) rend))
57
54
58Examples
55Examples
59--------
56--------
@@ -75,7 +72,7 @@ Accepts
75Produces
72Produces
76--------
73--------
77
74
78−`lot` is a [`++coin`]().
75+`lot` is a `++coin`.
79
76
80Source
77Source
81------
78------
@@ -104,216 +101,145 @@ Accepts
104Produces
101Produces
105--------
102--------
106
103
107−`lot` is a [`++coin`]().
104+`lot` is a `++coin`.
108
105
109Source
106Source
110------
107------
111
108
112− ++ rend
109+ ++ rend
113− ^- tape
110+ ^- tape
114− ?: ?=(%blob -.lot)
111+ ?: ?=($blob -.lot)
115− ['~' '0' ((v-co 1) (jam p.lot))]
112+ ['~' '0' ((v-co 1) (jam p.lot))]
116− ?: ?=(%many -.lot)
113+ ?: ?=($many -.lot)
117− :- '.'
114+ :- '.'
118− |- ^- tape
115+ |- ^- tape
119− ?~ p.lot
116+ ?~ p.lot
120− ['_' '_' rex]
117+ ['_' '_' rep]
121− ['_' (weld (trip (wack rent(lot i.p.lot))) $(p.lot t.p.lot))]
118+ ['_' (weld (trip (wack rent(lot i.p.lot))) $(p.lot t.p.lot))]
122− =+ [yed=(end 3 1 p.p.lot) hay=(cut 3 [1 1] p.p.lot)]
119+ =+ [yed=(end 3 1 p.p.lot) hay=(cut 3 [1 1] p.p.lot)]
123− |- ^- tape
120+ |- ^- tape
124− ?+ yed (z-co q.p.lot)
121+ ?+ yed (z-co q.p.lot)
125− %c ['~' '-' (weld (rip 3 (wood (tuft q.p.lot))) rex)]
122+ $c ['~' '-' (weld (rip 3 (wood (tuft q.p.lot))) rep)]
126− %d
123+ $d
127− ?+ hay (z-co q.p.lot)
124+ ?+ hay (z-co q.p.lot)
128− %a
125+ $a
129− =+ yod=(yore q.p.lot)
126+ =+ yod=(yore q.p.lot)
130− => ^+(. .(rex ?~(f.t.yod rex ['.' (s-co f.t.yod)])))
127+ => ^+(. .(rep ?~(f.t.yod rep ['.' (s-co f.t.yod)])))
131− => ^+ .
128+ => ^+ .
132− %= .
129+ %= .
133− rex
130+ rep
134− ?: &(=(~ f.t.yod) =(0 h.t.yod) =(0 m.t.yod) =(0 s.t.yod))
131+ ?: &(=(~ f.t.yod) =(0 h.t.yod) =(0 m.t.yod) =(0 s.t.yod))
135− rex
132+ rep
136− => .(rex ['.' (y-co s.t.yod)])
133+ => .(rep ['.' (y-co s.t.yod)])
137− => .(rex ['.' (y-co m.t.yod)])
134+ => .(rep ['.' (y-co m.t.yod)])
138− ['.' '.' (y-co h.t.yod)]
135+ ['.' '.' (y-co h.t.yod)]
139− ==
140− => .(rex ['.' (a-co d.t.yod)])
141− => .(rex ['.' (a-co m.yod)])
142− => .(rex ?:(a.yod rex ['-' rex]))
143− ['~' (a-co y.yod)]
144− ::
145− %r
146− =+ yug=(yell q.p.lot)
147− => ^+(. .(rex ?~(f.yug rex ['.' (s-co f.yug)])))
148− :- '~'
149− ?: &(=(0 d.yug) =(0 m.yug) =(0 h.yug) =(0 s.yug))
150− ['.' 's' '0' rex]
151− => ^+(. ?:(=(0 s.yug) . .(rex ['.' 's' (a-co s.yug)])))
152− => ^+(. ?:(=(0 m.yug) . .(rex ['.' 'm' (a-co m.yug)])))
153− => ^+(. ?:(=(0 h.yug) . .(rex ['.' 'h' (a-co h.yug)])))
154− => ^+(. ?:(=(0 d.yug) . .(rex ['.' 'd' (a-co d.yug)])))
155− +.rex
156− ==
157− ::
158− %f
159− ?: =(& q.p.lot)
160− ['.' 'y' rex]
161− ?:(=(| q.p.lot) ['.' 'n' rex] (z-co q.p.lot))
162− ::
163− %n ['~' rex]
164− %i
165− ?+ hay (z-co q.p.lot)
166− %f ((ro-co [3 10 4] |=(a=@ ~(d ne a))) q.p.lot)
167− %s ((ro-co [4 16 8] |=(a=@ ~(x ne a))) q.p.lot)
168− ==
169− ::
170− %p
171− =+ dyx=(met 3 q.p.lot)
172− :- '~'
173− ?: (lte dyx 1)
174− (weld (trip (tod:po q.p.lot)) rex)
175− ?: =(2 dyx)
176− ;: weld
177− (trip (tos:po (end 3 1 q.p.lot)))
178− (trip (tod:po (rsh 3 1 q.p.lot)))
179− rex
180− ==
181− =+ [dyz=(met 5 q.p.lot) fin=|]
182− |- ^- tape
183− ?: =(0 dyz)
184− rex
185− %= $
186− fin &
187− dyz (dec dyz)
188− q.p.lot (rsh 5 1 q.p.lot)
189− rex
190− =+ syb=(wren:un (end 5 1 q.p.lot))
191− =+ cog=~(zig mu [(rsh 4 1 syb) (end 4 1 syb)])
192− ;: weld
193− (trip (tos:po (end 3 1 p.cog)))
194− (trip (tod:po (rsh 3 1 p.cog)))
195− `tape`['-' ~]
196− (trip (tos:po (end 3 1 q.cog)))
197− (trip (tod:po (rsh 3 1 q.cog)))
198− `tape`?:(fin ['-' ?:(=(1 (end 0 1 dyz)) ~ ['-' ~])] ~)
199− rex
200 ==
136 ==
201− ==
137+ => .(rep ['.' (a-co d.t.yod)])
202− ::
138+ => .(rep ['.' (a-co m.yod)])
203− %r
139+ => .(rep ?:(a.yod rep ['-' rep]))
204− ?+ hay (z-co q.p.lot)
140+ ['~' (a-co y.yod)]
205− %d
206− =+ r=(rlyd q.p.lot)
207− ?~ e.r
208− ['.' '~' (r-co r)]
209− ['.' '~' u.e.r]
210− %h ['.' '~' '~' (r-co (rlyh q.p.lot))]
211− %q ['.' '~' '~' '~' (r-co (rlyq q.p.lot))]
212− %s ['.' (r-co (rlys q.p.lot))]
213− ==
214− ::
215− %u
216− =- (weld p.gam ?:(=(0 q.p.lot) `tape`['0' ~] q.gam))
217− ^= gam ^- [p=tape q=tape]
218− ?+ hay [~ ((ox-co [10 3] |=(a=@ ~(d ne a))) q.p.lot)]
219− %b [['0' 'b' ~] ((ox-co [2 4] |=(a=@ ~(d ne a))) q.p.lot)]
220− %i [['0' 'i' ~] ((d-co 1) q.p.lot)]
221− %x [['0' 'x' ~] ((ox-co [16 4] |=(a=@ ~(x ne a))) q.p.lot)]
222− %v [['0' 'v' ~] ((ox-co [32 5] |=(a=@ ~(x ne a))) q.p.lot)]
223− %w [['0' 'w' ~] ((ox-co [64 5] |=(a=@ ~(w ne a))) q.p.lot)]
224− ==
225− ::
226− %s
227− %+ weld
228− ?:((syn:si q.p.lot) "--" "-")
229− $(yed 'u', q.p.lot (abs:si q.p.lot))
230− ::
231− %t
232− ?: =('a' hay)
233− ?: =('s' (cut 3 [2 1] p.p.lot))
234−
235− (weld (rip 3 q.p.lot) rex)
236− ['~' '.' (weld (rip 3 q.p.lot) rex)]
237− ['~' '~' (weld (rip 3 (wood q.p.lot)) rex)]
238− ==
239− --
240− =+ rex=*tape
241− =< |%
242− ++ a-co |=(dat=@ ((d-co 1) dat))
243− ++ d-co |=(min=@ (em-co [10 min] |=([? b=@ c=tape] [~(d ne b) c])))
244− ++ r-co
245− |= [syn=? nub=@ der=@ ign=(unit tape) ne=?]
246− => .(rex ['.' (t-co ((d-co 1) der) ne)])
247− => .(rex ((d-co 1) nub))
248− ?:(syn rex ['-' rex])
249− ++ t-co |= [a=tape n=?] ^- tape
250− ?: n a
251− ?~ a ~|(%empty-frac !!) t.a
252 ::
141 ::
253− ++ s-co
142+ $r
254− |= esc=(list ,@) ^- tape
143+ =+ yug=(yell q.p.lot)
255− ~| [%so-co esc]
144+ => ^+(. .(rep ?~(f.yug rep ['.' (s-co f.yug)])))
256− ?~ esc
257− rex
258− :- '.'
145+ :- '~'
259− =>(.(rex $(esc t.esc)) ((x-co 4) i.esc))
146+ ?: &(=(0 d.yug) =(0 m.yug) =(0 h.yug) =(0 s.yug))
260−
147+ ['s' '0' rep]
148+ => ^+(. ?:(=(0 s.yug) . .(rep ['.' 's' (a-co s.yug)])))
149+ => ^+(. ?:(=(0 m.yug) . .(rep ['.' 'm' (a-co m.yug)])))
150+ => ^+(. ?:(=(0 h.yug) . .(rep ['.' 'h' (a-co h.yug)])))
151+ => ^+(. ?:(=(0 d.yug) . .(rep ['.' 'd' (a-co d.yug)])))
152+ +.rep
153+ ==
261 ::
154 ::
262− ++ v-co |=(min=@ (em-co [32 min] |=([? b=@ c=tape] [~(v ne b) c])))
155+ $f
263− ++ w-co |=(min=@ (em-co [64 min] |=([? b=@ c=tape] [~(w ne b) c])))
156+ ?: =(& q.p.lot)
264− ++ x-co |=(min=@ (em-co [16 min] |=([? b=@ c=tape] [~(x ne b) c])))
157+ ['.' 'y' rep]
265− ++ y-co |=(dat=@ ((d-co 2) dat))
158+ ?:(=(| q.p.lot) ['.' 'n' rep] (z-co q.p.lot))
266− ++ z-co |=(dat=@ `tape`['0' 'x' ((x-co 1) dat)])
159+ ::
267− --
160+ $n ['~' rep]
268− ~% %co +> ~
161+ $i
269− |%
162+ ?+ hay (z-co q.p.lot)
270− ++ em-co
163+ $f ((ro-co [3 10 4] |=(a/@ ~(d ne a))) q.p.lot)
271− ~/ %emco
164+ $s ((ro-co [4 16 8] |=(a/@ ~(x ne a))) q.p.lot)
272− |= [[bas=@ min=@] [par=$+([? @ tape] tape)]]
165+ ==
273− |= hol=@
166+ ::
274− ^- tape
167+ $p
275− ?: &(=(0 hol) =(0 min))
168+ =+ dyx=(met 3 q.p.lot)
276− rex
169+ :- '~'
277− =+ [rad=(mod hol bas) dar=(div hol bas)]
170+ ?: (lte dyx 1)
278− %= $
171+ (weld (trip (tod:po q.p.lot)) rep)
279− min ?:(=(0 min) 0 (dec min))
172+ ?: =(2 dyx)
280− hol dar
173+ ;: weld
281− rex (par =(0 dar) rad rex)
174+ (trip (tos:po (end 3 1 q.p.lot)))
175+ (trip (tod:po (rsh 3 1 q.p.lot)))
176+ rep
177+ ==
178+ =+ [dyz=(met 5 q.p.lot) fin=| dub=&]
179+ |- ^- tape
180+ ?: =(0 dyz)
181+ rep
182+ %= $
183+ fin &
184+ dub !dub
185+ dyz (dec dyz)
186+ q.p.lot (rsh 5 1 q.p.lot)
187+ rep
188+ =+ syb=(wren:un (end 5 1 q.p.lot))
189+ =+ cog=~(zig mu [(rsh 4 1 syb) (end 4 1 syb)])
190+ ;: weld
191+ (trip (tos:po (end 3 1 p.cog)))
192+ (trip (tod:po (rsh 3 1 p.cog)))
193+ `tape`['-' ~]
194+ (trip (tos:po (end 3 1 q.cog)))
195+ (trip (tod:po (rsh 3 1 q.cog)))
196+ `tape`?.(fin ~ ['-' ?.(dub ~ ['-' ~])])
197+ rep
198+ ==
199+ ==
200+ ::
201+ $r
202+ ?+ hay (z-co q.p.lot)
203+ $d ['.' '~' (r-co (rlyd q.p.lot))]
204+ $h ['.' '~' '~' (r-co (rlyh q.p.lot))]
205+ $q ['.' '~' '~' '~' (r-co (rlyq q.p.lot))]
206+ $s ['.' (r-co (rlys q.p.lot))]
207+ ==
208+ ::
209+ $u
210+ ?: ?=($c hay)
211+ %+ welp ['0' 'c' (reap (pad:fa q.p.lot) '1')]
212+ (c-co (enc:fa q.p.lot))
213+ =- (weld p.gam ?:(=(0 q.p.lot) `tape`['0' ~] q.gam))
214+ ^= gam ^- {p/tape q/tape}
215+ ?+ hay [~ ((ox-co [10 3] |=(a/@ ~(d ne a))) q.p.lot)]
216+ $b [['0' 'b' ~] ((ox-co [2 4] |=(a/@ ~(d ne a))) q.p.lot)]
217+ $i [['0' 'i' ~] ((d-co 1) q.p.lot)]
218+ $x [['0' 'x' ~] ((ox-co [16 4] |=(a/@ ~(x ne a))) q.p.lot)]
219+ $v [['0' 'v' ~] ((ox-co [32 5] |=(a/@ ~(x ne a))) q.p.lot)]
220+ $w [['0' 'w' ~] ((ox-co [64 5] |=(a/@ ~(w ne a))) q.p.lot)]
221+ ==
222+ ::
223+ $s
224+ %+ weld
225+ ?:((syn:si q.p.lot) "--" "-")
226+ $(yed 'u', q.p.lot (abs:si q.p.lot))
227+ ::
228+ $t
229+ ?: =('a' hay)
230+ ?: =('s' (cut 3 [2 1] p.p.lot))
231+ (weld (rip 3 q.p.lot) rep)
232+ ['~' '.' (weld (rip 3 q.p.lot) rep)]
233+ ['~' '~' (weld (rip 3 (wood q.p.lot)) rep)]
282 ==
234 ==
283− ::
284− ++ ox-co
285− ~/ %oxco
286− |= [[bas=@ gop=@] dug=$+(@ @)]
287− %+ em-co
288− [|-(?:(=(0 gop) 1 (mul bas $(gop (dec gop))))) 0]
289− |= [top=? seg=@ res=tape]
290− %+ weld
291− ?:(top ~ `tape`['.' ~])
292− %. seg
293− %+ em-co(rex res)
294− [bas ?:(top 0 gop)]
295− |=([? b=@ c=tape] [(dug b) c])
296− ::
297− ++ ro-co
298− ~/ %roco
299− |= [[buz=@ bas=@ dop=@] dug=$+(@ @)]
300− |= hol=@
301− ^- tape
302− ?: =(0 dop)
303− rex
304− => .(rex $(dop (dec dop)))
305− :- '.'
306− %- (em-co [bas 1] |=([? b=@ c=tape] [(dug b) c]))
307− [(cut buz [(dec dop) 1] hol)]
308 --
235 --
309− ::
310
236
311Examples
237Examples
312--------
238--------
313
239
314 ~zod/try=> ~(rend co ~ %ux 200)
240 ~zod/try=> ~(rend co ~ %ux 200)
315 "0xc8"
241 "0xc8"
316− ~zod/try=> ~(rend co %many ~[[%$ ux/200] [%$ p/40]])
242+ ~zod/try=> ~(rend co %many ~[[%$ ux+200] [%$ p+40]])
317 "._0xc8_~~tem__"
243 "._0xc8_~~tem__"
318 ~zod/try=> ~(rend co ~ %p 32.819)
244 ~zod/try=> ~(rend co ~ %p 32.819)
319 "~pillyt"
245 "~pillyt"
docs/system/hoon/library/src/4k/gate/iny.md+3−3
@@ -2,13 +2,13 @@
2
2
3Indentation block
3Indentation block
4
4
5−Apply [`++rule`]() to indented block starting at current column number, omitting
5+Apply `++rule` to indented block starting at current column number, omitting
6the leading whitespace.
6the leading whitespace.
7
7
8Accepts
8Accepts
9-------
9-------
10
10
11−`sef` is a [`++rule`]()
11+`sef` is a `++rule`
12
12
13Produces
13Produces
14--------
14--------
@@ -18,7 +18,7 @@ A `++rule`.
18Source
18Source
19------
19------
20
20
21− ++ iny |* sef=_rule :: indentation block
21+ ++ inde |* sef/rule :: indentation block
22 |= nail ^+ (sef)
22 |= nail ^+ (sef)
23 =+ [har tap]=[p q]:+<
23 =+ [har tap]=[p q]:+<
24 =+ lev=(fil 3 (dec q.har) ' ')
24 =+ lev=(fil 3 (dec q.har) ' ')
docs/system/hoon/library/src/4k/gate/mes.md+1−1
@@ -8,7 +8,7 @@ Source
8------
8------
9
9
10 ++ mes %+ cook :: hexbyte
10 ++ mes %+ cook :: hexbyte
11− |=([a=@ b=@] (add (mul 16 a) b))
11+ |=({a/@ b/@} (add (mul 16 a) b))
12 ;~(plug hit hit)
12 ;~(plug hit hit)
13
13
14Examples
14Examples
docs/system/hoon/library/src/4k/gate/ven.md+2−2
@@ -7,10 +7,10 @@ Axis syntax parser
7Source
7Source
8------
8------
9
9
10− ++ ven ;~ (comp |=([a=@ b=@] (peg a b))) :: +>- axis syntax
10+ ++ ven ;~ (comp |=({a/@ b/@} (peg a b))) :: +>- axis syntax
11 bet
11 bet
12 =+ hom=`?`|
12 =+ hom=`?`|
13− |= tub=nail
13+ |= tub/nail
14 ^- (like axis)
14 ^- (like axis)
15 =+ vex=?:(hom (bet tub) (gul tub))
15 =+ vex=?:(hom (bet tub) (gul tub))
16 ?~ q.vex
16 ?~ q.vex
docs/system/hoon/library/src/4k/gate/vit.md+3−3
@@ -9,9 +9,9 @@ Source
9
9
10 ++ vit :: base64 digit
10 ++ vit :: base64 digit
11 ;~ pose
11 ;~ pose
12− (cook |=(a=@ (sub a 65)) (shim 'A' 'Z'))
12+ (cook |=(a/@ (sub a 65)) (shim 'A' 'Z'))
13− (cook |=(a=@ (sub a 71)) (shim 'a' 'z'))
13+ (cook |=(a/@ (sub a 71)) (shim 'a' 'z'))
14− (cook |=(a=@ (add a 4)) (shim '0' '9'))
14+ (cook |=(a/@ (add a 4)) (shim '0' '9'))
15 (cold 62 (just '-'))
15 (cold 62 (just '-'))
16 (cold 63 (just '+'))
16 (cold 63 (just '+'))
17 ==
17 ==
docs/system/hoon/library/src/4k/gate/vul.md+1−1
@@ -5,7 +5,7 @@ Comments to null
5Source
5Source
6------
6------
7
7
8− ++ vul %- cold :- ~ :: comments
8+ ++ vul %+ cold ~ :: comments
9 ;~ plug col col
9 ;~ plug col col
10 (star prn)
10 (star prn)
11 (just `@`10)
11 (just `@`10)
docs/system/hoon/library/src/4l/core/.so.md.swpnew file

Binary file not shown.

docs/system/hoon/library/src/4l/core/so.md+195−76
@@ -2,7 +2,7 @@
2
2
3Coin parser engine
3Coin parser engine
4
4
5−Core containing arms that parse [`++coin`]s.
5+Core containing arms that parse `++coin`.
6
6
7Accepts
7Accepts
8-------
8-------
@@ -29,7 +29,7 @@ Examples
29Parse odor-atom pair
29Parse odor-atom pair
30
30
31Parsing rule. Parses an unsigned integer of any permitted base,
31Parsing rule. Parses an unsigned integer of any permitted base,
32−producing a [`++dime`]().
32+producing a `++dime`.
33
33
34Accepts
34Accepts
35-------
35-------
@@ -69,8 +69,8 @@ Examples
69Parse `@da`, `@dr`, `@p`, `@t`
69Parse `@da`, `@dr`, `@p`, `@t`
70
70
71Parsing rule. Parses any atom of any of the following odors after a
71Parsing rule. Parses any atom of any of the following odors after a
72−leading sig, `~` into a [`++dime`](): [`@da`](), [`@dr`](), [`@p`](),
72+leading sig, `~` into a `++dime`: `@da`, `@dr`, `@p`,
73−and [`@t`](), producing a [`++dime`]().
73+and `@t`, producing a `++dime`.
74
74
75Accepts
75Accepts
76-------
76-------
@@ -82,12 +82,13 @@ Source
82------
82------
83
83
84 ++ crub
84 ++ crub
85+ ~+
85 ;~ pose
86 ;~ pose
86 %+ cook
87 %+ cook
87− |=(det=date `dime`[%da (year det)])
88+ |=(det/date `dime`[%da (year det)])
88 ;~ plug
89 ;~ plug
89 %+ cook
90 %+ cook
90− |=([a=@ b=?] [b a])
91+ |=({a/@ b/?} [b a])
91 ;~(plug dim:ag ;~(pose (cold | hep) (easy &)))
92 ;~(plug dim:ag ;~(pose (cold | hep) (easy &)))
92 ;~(pfix dot dim:ag) :: month
93 ;~(pfix dot dim:ag) :: month
93 ;~(pfix dot dim:ag) :: day
94 ;~(pfix dot dim:ag) :: day
@@ -106,16 +107,16 @@ Source
106 ==
107 ==
107 ::
108 ::
108 %+ cook
109 %+ cook
109− |= [a=(list ,[p=?(%d %h %m %s) q=@]) b=(list ,@)]
110+ |= {a/(list {p/?($d $h $m $s) q/@}) b/(list @)}
110 =+ rop=`tarp`[0 0 0 0 b]
111 =+ rop=`tarp`[0 0 0 0 b]
111 |- ^- dime
112 |- ^- dime
112 ?~ a
113 ?~ a
113 [%dr (yule rop)]
114 [%dr (yule rop)]
114 ?- p.i.a
115 ?- p.i.a
115− %d $(a t.a, d.rop (add q.i.a d.rop))
116+ $d $(a t.a, d.rop (add q.i.a d.rop))
116− %h $(a t.a, h.rop (add q.i.a h.rop))
117+ $h $(a t.a, h.rop (add q.i.a h.rop))
117− %m $(a t.a, m.rop (add q.i.a m.rop))
118+ $m $(a t.a, m.rop (add q.i.a m.rop))
118− %s $(a t.a, s.rop (add q.i.a s.rop))
119+ $s $(a t.a, s.rop (add q.i.a s.rop))
119 ==
120 ==
120 ;~ plug
121 ;~ plug
121 %+ most
122 %+ most
@@ -131,20 +132,122 @@ Source
131 ::
132 ::
132 (stag %p fed:ag)
133 (stag %p fed:ag)
133 ;~(pfix dot (stag %ta urs:ab))
134 ;~(pfix dot (stag %ta urs:ab))
134− ;~(pfix sig (stag %t (cook woad urs:ab)))
135+ ;~(pfix sig (stag %t urx:ab))
135− ;~(pfix hep (stag %c (cook turf (cook woad urs:ab))))
136+ ;~(pfix hep (stag %c (cook turf urx:ab)))
136 ==
137 ==
138+ ++ nuck
139+ ~/ %nuck |= a/nail %. a
140+ %+ knee *coin |. ~+
141+ %- stew
142+ ^. stet ^. limo
143+ :~ :- ['a' 'z'] (cook |=(a/@ta [%$ %tas a]) sym)
144+ :- ['0' '9'] (stag %$ bisk)
145+ :- '-' (stag %$ tash)
146+ :- '.' ;~(pfix dot perd)
147+ :- '~' ;~(pfix sig ;~(pose twid (easy [%$ %n 0])))
148+ ==
149+ ++ nusk
150+ ~+
151+ :(sear |=(a/@ta (rush a nuck)) wick urt:ab)
152+ ++ perd
153+ ~+
154+ ;~ pose
155+ (stag %$ zust)
156+ (stag %many (ifix [cab ;~(plug cab cab)] (more cab nusk)))
157+ ==
158+ ++ royl
159+ ~+
160+ =+ ^= moo
161+ |= a/tape
162+ :- (lent a)
163+ (scan a (bass 10 (plus sid:ab)))
164+ =+ ^= voy
165+ %+ cook royl-cell
166+ ;~ pose
167+ ;~ plug
168+ (easy %d)
169+ ;~ pose (cold | hep) (easy &) ==
170+ ;~ plug dim:ag
171+ ;~ pose
172+ ;~(pfix dot (cook moo (plus (shim '0' '9'))))
173+ (easy [0 0])
174+ ==
175+ ;~ pose
176+ ;~ pfix
177+ (just 'e')
178+ ;~(plug ;~(pose (cold | hep) (easy &)) dim:ag)
179+ ==
180+ (easy [& 0])
181+ ==
182+ ==
183+ ==
184+ ;~ plug
185+ (easy %i)
186+ ;~ sfix
187+ ;~ pose (cold | hep) (easy &) ==
188+ (jest 'inf')
189+ ==
190+ ==
191+ ;~ plug
192+ (easy %n)
193+ (cold ~ (jest 'nan'))
194+ ==
195+ ==
196+ ;~ pose
197+ (stag %rh (cook rylh ;~(pfix ;~(plug sig sig) voy)))
198+ (stag %rq (cook rylq ;~(pfix ;~(plug sig sig sig) voy)))
199+ (stag %rd (cook ryld ;~(pfix sig voy)))
200+ (stag %rs (cook ryls voy))
201+ ==
202+ ::
203+ ++ royl-cell
204+ |= rn
205+ ^- dn
206+ ?. ?=({$d *} +<) +<
207+ =+ ^= h
208+ (dif:si (new:si f.b i.b) (sun:si d.b))
209+ [%d a h (add (mul c.b (pow 10 d.b)) e.b)]
210+ ::
211+ ++ tash
212+ ~+
213+ =+ ^= neg
214+ |= {syn/? mol/dime} ^- dime
215+ ?> =('u' (end 3 1 p.mol))
216+ [(cat 3 's' (rsh 3 1 p.mol)) (new:si syn q.mol)]
217+ ;~ pfix hep
218+ ;~ pose
219+ (cook |=(a/dime (neg | a)) bisk)
220+ ;~(pfix hep (cook |=(a/dime (neg & a)) bisk))
221+ ==
222+ ==
223+ ::
224+ ++ twid
225+ ~+
226+ ;~ pose
227+ (cook |=(a/@ [%blob (cue a)]) ;~(pfix (just '0') vum:ag))
228+ (stag %$ crub)
229+ ==
230+ ::
231+ ++ zust
232+ ~+
233+ ;~ pose
234+ (stag %is bip:ag)
235+ (stag %if lip:ag)
236+ (stag %f ;~(pose (cold & (just 'y')) (cold | (just 'n'))))
237+ royl
238+ ==
239+ --
137
240
138Examples
241Examples
139--------
242--------
140
243
141 ~zod/try=> (scan "1926.5.12" crub:so)
244 ~zod/try=> (scan "1926.5.12" crub:so)
142 [p=~.da q=170.141.184.449.747.016.871.285.095.307.149.312.000]
245 [p=~.da q=170.141.184.449.747.016.871.285.095.307.149.312.000]
143− ~zod/try=> (,[%da @da] (scan "1926.5.12" crub:so))
246+ ~zod/try=> ([%da @da] (scan "1926.5.12" crub:so))
144 [%da ~1926.5.12]
247 [%da ~1926.5.12]
145 ~zod/try=> (scan "s10" crub:so)
248 ~zod/try=> (scan "s10" crub:so)
146 [p=~.dr q=184.467.440.737.095.516.160]
249 [p=~.dr q=184.467.440.737.095.516.160]
147− ~zod/try=> (,[%dr @dr] (scan "s10" crub:so))
250+ ~zod/try=> ([%dr @dr] (scan "s10" crub:so))
148 [%dr ~s10]
251 [%dr ~s10]
149 ~zod/try=> (scan "doznec" crub:so)
252 ~zod/try=> (scan "doznec" crub:so)
150 [%p 256]
253 [%p 256]
@@ -158,7 +261,7 @@ Examples
158Top-level coin parser
261Top-level coin parser
159
262
160Parsing rule. Switches on the first character and applies the
263Parsing rule. Switches on the first character and applies the
161−corresponding [`++coin`]() parser.
264+corresponding `++coin` parser.
162
265
163Accepts
266Accepts
164-------
267-------
@@ -169,16 +272,19 @@ Produces
169Source
272Source
170------
273------
171
274
172− ++ nuck
275+ ++ nuck
276+ ~/ %nuck |= a/nail %. a
173− %+ knee *coin |. ~+
277+ %+ knee *coin |. ~+
174− %- stew
278+ %- stew
175− ^. stet ^. limo
279+ ^. stet ^. limo
176− :~ :- ['a' 'z'] (cook |=(a=@ta [~ %tas a]) sym)
280+ :~ :- ['a' 'z'] (cook |=(a/@ta [%$ %tas a]) sym)
177− :- ['0' '9'] (stag ~ bisk)
281+ :- ['0' '9'] (stag %$ bisk)
178− :- '-' (stag ~ tash)
282+ :- '-' (stag %$ tash)
179− :- '.' ;~(pfix dot perd)
283+ :- '.' ;~(pfix dot perd)
180− :- '~' ;~(pfix sig ;~(pose twid (easy [~ %n 0])))
284+ :- '~' ;~(pfix sig ;~(pose twid (easy [%$ %n 0])))
181− ==
285+ ==
286+
287+
182
288
183Examples
289Examples
184--------
290--------
@@ -224,7 +330,7 @@ Source
224------
330------
225
331
226 ++ nusk
332 ++ nusk
227− (sear |=(a=@ta (rush (wick a) nuck)) urt:ab)
333+ (sear |=(a/@ta (rush (wick a) nuck)) urt:ab)
228
334
229Examples
335Examples
230--------
336--------
@@ -235,7 +341,7 @@ Examples
235 [1 ~.asd_a]
341 [1 ~.asd_a]
236 ~zod/try=> (scan "~~.asd~-a" nusk:so)
342 ~zod/try=> (scan "~~.asd~-a" nusk:so)
237 [% p=[p=~.ta q=418.212.246.369]]
343 [% p=[p=~.ta q=418.212.246.369]]
238− ~zod/try=> (,[~ %ta @ta] (scan "~~.asd~-a" nusk:so))
344+ ~zod/try=> ([~ %ta @ta] (scan "~~.asd~-a" nusk:so))
239 [~ %ta ~.asd_a]
345 [~ %ta ~.asd_a]
240
346
241------------------------------------------------------------------------
347------------------------------------------------------------------------
@@ -280,7 +386,7 @@ Examples
280
386
281Parse dime float
387Parse dime float
282
388
283−Parsing rule. Parses a number into a [`++dime`]() float.
389+Parsing rule. Parses a number into a `++dime` float.
284
390
285Accepts
391Accepts
286-------
392-------
@@ -291,28 +397,51 @@ Produces
291Source
397Source
292------
398------
293
399
294− ++ royl
400+ ++ royl
295− =+ ^= zer
401+ ~+
296− (cook lent (star (just '0')))
402+ =+ ^= moo
403+ |= a/tape
404+ :- (lent a)
405+ (scan a (bass 10 (plus sid:ab)))
297− =+ ^= voy
406+ =+ ^= voy
298− %+ cook royl-cell
407+ %+ cook royl-cell
299− ;~ plug
408+ ;~ pose
409+ ;~ plug
410+ (easy %d)
300− ;~(pose (cold | hep) (easy &))
411+ ;~ pose (cold | hep) (easy &) ==
301− ;~(plug dim:ag ;~(pose ;~(pfix dot ;~(plug zer dim:ag)) (easy [0 0])))
412+ ;~ plug dim:ag
413+ ;~ pose
414+ ;~(pfix dot (cook moo (plus (shim '0' '9'))))
415+ (easy [0 0])
416+ ==
302− ;~ pose
417+ ;~ pose
303− ;~ pfix
418+ ;~ pfix
304− (just 'e')
419+ (just 'e')
305− (cook some ;~(plug ;~(pose (cold | hep) (easy &)) dim:ag))
420+ ;~(plug ;~(pose (cold | hep) (easy &)) dim:ag)
306− ==
307− (easy ~)
308 ==
421 ==
422+ (easy [& 0])
309 ==
423 ==
424+ ==
425+ ==
426+ ;~ plug
427+ (easy %i)
428+ ;~ sfix
310− ;~ pose
429+ ;~ pose (cold | hep) (easy &) ==
311− (stag %rh (cook rylh ;~(pfix ;~(plug sig sig) voy)))
430+ (jest 'inf')
312− (stag %rq (cook rylq ;~(pfix ;~(plug sig sig sig) voy)))
431+ ==
313− (stag %rd (cook ryld ;~(pfix sig voy)))
432+ ==
314− (stag %rs (cook ryls voy)
433+ ;~ plug
434+ (easy %n)
435+ (cold ~ (jest 'nan'))
315 ==
436 ==
437+ ==
438+ ;~ pose
439+ (stag %rh (cook rylh ;~(pfix ;~(plug sig sig) voy)))
440+ (stag %rq (cook rylq ;~(pfix ;~(plug sig sig sig) voy)))
441+ (stag %rd (cook ryld ;~(pfix sig voy)))
442+ (stag %rs (cook ryls voy))
443+ ==
444+ ::
316
445
317Examples
446Examples
318--------
447--------
@@ -330,6 +459,15 @@ XX still not fully functional
330
459
331Intermediate parsed float convereter
460Intermediate parsed float convereter
332
461
462+ ++ royl-cell
463+ |= rn
464+ ^- dn
465+ ?. ?=({$d *} +<) +<
466+ =+ ^= h
467+ (dif:si (new:si f.b i.b) (sun:si d.b))
468+ [%d a h (add (mul c.b (pow 10 d.b)) e.b)]
469+ ::
470+
333------------------------------------------------------------------------
471------------------------------------------------------------------------
334
472
335### `++tash`
473### `++tash`
@@ -339,46 +477,27 @@ Parse signed dime
339Accepts
477Accepts
340-------
478-------
341
479
342−Accepts
343−-------
344−
345Produces
480Produces
346--------
481--------
347
482
348−Produces
349−--------
350−
351−Parsing rule. Parses a signed number into a [`++dime`]().
483+Parsing rule. Parses a signed number into a `++dime`.
352−
353−Source
354−------
355−
356− ++ royl-cell
357− |= [a=? b=[c=@ d=@ e=@] f=(unit ,[h=? i=@])]
358− ^- [? @ @ @ (unit ,@s)]
359− ?~ f
360− [a c.b d.b e.b ~]
361− ?: h.u.f
362− [a c.b d.b e.b [~ (mul i.u.f 2)]]
363− [a c.b d.b e.b [~ (dec (mul i.u.f 2))]]
364−
365−Examples
366−--------
367
484
368Source
485Source
369------
486------
370
487
371 ++ tash
488 ++ tash
489+ ~+
372 =+ ^= neg
490 =+ ^= neg
373− |= [syn=? mol=dime] ^- dime
491+ |= {syn/? mol/dime} ^- dime
374 ?> =('u' (end 3 1 p.mol))
492 ?> =('u' (end 3 1 p.mol))
375 [(cat 3 's' (rsh 3 1 p.mol)) (new:si syn q.mol)]
493 [(cat 3 's' (rsh 3 1 p.mol)) (new:si syn q.mol)]
376 ;~ pfix hep
494 ;~ pfix hep
377 ;~ pose
495 ;~ pose
378− (cook |=(a=dime (neg | a)) bisk)
496+ (cook |=(a/dime (neg | a)) bisk)
379− ;~(pfix hep (cook |=(a=dime (neg & a)) bisk))
497+ ;~(pfix hep (cook |=(a/dime (neg & a)) bisk))
380 ==
498 ==
381 ==
499 ==
500+ ::
382
501
383Examples
502Examples
384--------
503--------
@@ -411,7 +530,7 @@ Source
411
530
412 ++ twid
531 ++ twid
413 ;~ pose
532 ;~ pose
414− (cook |=(a=@ [%blob (cue a)]) ;~(pfix (just '0') vum:ag))
533+ (cook |=(a/@ [%blob (cue a)]) ;~(pfix (just '0') vum:ag))
415 (stag ~ crub)
534 (stag ~ crub)
416 ==
535 ==
417 ::
536 ::
@@ -436,8 +555,8 @@ Examples
436
555
437Parse prefixed dimes from `@if`, `@f`, `@rd`
556Parse prefixed dimes from `@if`, `@f`, `@rd`
438
557
439−Parsing rule. Parses an atom of either [`@if`]() (IP address), [`@f`]()
558+Parsing rule. Parses an atom of either `@if` (IP address), `@f`
440−(loobean), or [`rf`]()(floating point) into a [`++dime`]().
559+(loobean), or `rf`(floating point) into a `++dime`.
441
560
442Accepts
561Accepts
443-------
562-------