on master help sign in
thru col
commit45b9c4110ac1537b92eb80dcd1306c4e09bafa74 authorHenry Ault <henry@tlon.io> dateMon 28 Mar 2016, 21:41 (11 years ago) parent32c88d6
7 files changed+38−205
docs/system/hoon/runes/cl/clcb.md+5−26 docs/system/hoon/runes/cl/clfs.md+2−23 docs/system/hoon/runes/cl/clhp.md+15−29 docs/system/hoon/runes/cl/clkt.md+3−36 docs/system/hoon/runes/cl/clls.md+5−29 docs/system/hoon/runes/cl/clsg.md+5−32 docs/system/hoon/runes/cl/cltr.md+3−30
docs/system/hoon/runes/cl/clcb.md+5−26
@@ -1,33 +1,12 @@
1−`:_ colcab`
2−===========
1+# `:scon`, `:_`, "colcab", `{$scon p/twig q/twig}`
32
43Inverted tuple of `p` `q`.
54
6−Exists for code readability and organization. See the [backstep]() convention.
5+Produces: a cell of `[q p]`. Exists for code readability and organization. See the backstep convention.
76
8−Produces
9−--------
7+Regular form: *2-fixed*
108
11−Twig: `[%clcb p=twig q=twig]`
12−
13−Accepts
14−-------
15−
16−`p` is a [++twig](). `q` is a twig.
17−
18−Tall form
19−---------
20−
21− :_ p
22− q
23−
24−Wide form
25−---------
26−
27− :_(p q)
28−
29−Examples
30−--------
9+Examples:
3110
3211 ~zod/try=> :_(1 2)
3312 [2 1]
@@ -38,7 +17,7 @@ reverse order.
3817 ~zod/try=> `tape`:_(~ 'a')
3918 "a"
4019
41−Since a [`++tape`]() is a null-terminated list of characters, casting
20+Since a `++tape` is a null-terminated list of characters, casting
4221the result of `:_(~ 'a')` to a `tape` produces `"a"`.
4322
4423 /~zod/try=>
docs/system/hoon/runes/cl/clfs.md+2−23
@@ -1,33 +1,12 @@
11`:/ colfas`
22===========
33
4−String to XML XX.
4+String to XML XX
55
66`:/`, `colfas`, is a synthetic rune that produces `[%$ [%$ p ~] ~]`,
77i.e., `[0 [0 p 0] 0]`.
88
9−Produces
10−--------
11−
12−Twig: `[%clfs p=twig]`
13−
14−Accepts
15−-------
16−
17−`p` is a [`++twig`]()
18−
19−Tall form
20−---------
21−
22− :/ p
23−
24−Wide form
25−---------
26−
27− :/(p)
28−
29−Examples
30−--------
9+Examples:
3110
3211 ~zod/try=> :/(20)
3312 [[%~. [%~. 20] ~] ~]
docs/system/hoon/runes/cl/clhp.md+15−29
@@ -1,36 +1,22 @@
1−`:- colhep`
2−===========
1+# `:cons`, `:-`, "colhep", `{$cons p/twig q/twig}`
32
43Tuple of two.
54
6−Produces
7−--------
5+Produces: a cell of `p` and `q`.
86
9−Twig: `[%clhp p=twig q=twig]`
7+Regular form: *2-fixed*
108
11−Accepts
12−-------
9+Irregular forms:
1310
14−`p` is a [++twig](). `q` is a twig.
11+```
12+[a b] :-(a b)
13+1^2^3 [1 2 3]
14+a+1 [%a 1]
15+`1 [~ 1]
16+[1 2]~ [[1 2] ~]
17+```
1518
16−Tall form
17−---------
18−
19− :- p
20− q
21−
22−Wide form
23−---------
24−
25− :-(p q)
26−
27−Irregular form
28−--------------
29−
30− [p q]
31−
32−Examples
33−--------
19+Examples:
3420
3521 ~zod/try=> :-(1 2)
3622 [1 2]
@@ -66,7 +52,7 @@ Some obscure `:-` irregular forms
6652 ~zod/main=/app> a/'twig'
6753 [%a 'twig']
6854
69−Like `^`, but first item must be a [`++term`](), and is [cube]()d. Used to construct [`path`]()s and [frond]().
55+Like `^`, but first item must be a `++term`, and is cubed. Used to construct `path`s and frond.
7056
7157### Prefix `` ` ``, postfix `~`
7258
@@ -75,5 +61,5 @@ Like `^`, but first item must be a [`++term`](), and is [cube]()d. Used to const
7561 ~zod/main=/app> [42 30]~
7662 [[42 30] ~]
7763
78−Complimenting each other, these construct pairs with `~` in the [head]() and
79−[`tail`]() respectively. Multiple postfix `~` do not work for unknown reasons.
64+Complimenting each other, these construct pairs with `~` in the head and
65+`tail` respectively. Multiple postfix `~` do not work for unknown reasons.
docs/system/hoon/runes/cl/clkt.md+3−36
@@ -1,45 +1,12 @@
1−`:^ colket`
2−===========
1+# `:conq`, `:^`, "colket", `{$conq p/twig q/twig r/twig s/twig}`
32
43Tuple of four.
54
6−Produces
7−--------
5+Produces: the tuple of `[p q r s]`.
86
9−Twig: `[%clkt p=twig q=twig r=twig s=twig]`
10−
11−Accepts
12−-------
13−
14−`p` is a [++twig](). `q` is a twig. `r` is a twig. `s` is a
15−twig.
16−
17−Tall form
18−---------
19−
20−Kingside:
21−
22− :^ p
23− q
24− r
25− s
26−
27−Queenside:
28−
29− :^ p q
30− r
31− s
32−
33− :^ p q r
34− s
35−
36−Wide form
37−---------
38−
39− :^(p q r s)
7+Regular form: *4-fixed*
408
419Examples
42−--------
4310
4411 /~zod/try=> :^(1 2 3 4)
4512 [1 2 3 4]
docs/system/hoon/runes/cl/clls.md+5−29
@@ -1,39 +1,15 @@
1−`:+ collus`
1+# `:cont`, `:+`, "collus", `{$cont p/twig q/twig r/twig}`
22===========
33
44Tuple of 3.
55
6−Produces
7−--------
6+Produces: the tuple of `p`, `q`, and `r`.
87
9−Twig: `[%clls p=twig q=twig r=twig]`
8+Regular form:
109
11−Accepts
12−-------
10+*3-fixed*
1311
14−`p` is a [++twig](). `q` is a twig. `r` is a twig.
15−
16−Tall form
17−---------
18−
19−Kingside:
20−
21− :+ p
22− q
23− r
24−
25−Queenside:
26−
27− :+ p q
28− r
29−
30−Wide form
31−---------
32−
33− :+(p q r)
34−
35−Examples
36−--------
12+Examples:
3713
3814 /~zod/try=> :+ 1
3915 2
docs/system/hoon/runes/cl/clsg.md+5−32
@@ -1,40 +1,13 @@
1−`:~ colsig`
1+# `:conl`, `:~`, "colsig", `{$conl p/(list twig)}`
22===========
33
44Null-terminated tuple of n elements.
55
6−Closed with `==`.
6+Produces: tuple of input elements. Closed with `==` in tall form.
77
8−Produces
9−--------
8+Regular form: *running*
109
11−Twig: `[%clsg p=tusk]`
12−
13−Accepts
14−-------
15−
16−`p` is a [`++tusk`](), a list of [`++twig`]()s.
17−
18−Tall form
19−---------
20−
21− :~ i.p
22− i.t.p
23− i.t.t.p
24− ==
25−
26−Wide form
27−---------
28−
29− :~(i.p i.t.p i.t.t.p)
30−
31−Irregular form
32−--------------
33−
34− ~[i.p i.t.p i.t.t.p]
35−
36−Examples
37−--------
10+Examples:
3811
3912 /~zod/try=> :~(5 3 4 2 1)
4013 [5 3 4 2 1 ~]
@@ -61,7 +34,7 @@ This is the most straightforward case of `:~`, producing a tuple in wide, irregu
6134 ~[1 2 4 3 5]
6235
6336In this example we use `%-` to pass the results of our previous example
64−to [`++limo`](), which creates a [`++list`](), and [`++flop`](), which
37+to `++limo`, which creates a `++list`, and `++flop`, which
6538reverses its order. This example shows how `:~` is commonly useful.
6639Null-terminated tuples are easily converted to lists, which are
6740frequently encountered in hoon.
docs/system/hoon/runes/cl/cltr.md+3−30
@@ -1,37 +1,10 @@
1−`:* coltar`
2−===========
1+# `:conp`, `:*`, "coltar", {$conp p/(list twig)}
32
43Tuple of n elements.
54
6−Closed with `==`.
5+Produces: tuple of input elements. Closed with `==`.
76
8−Produces
9−--------
10−
11−Twig: `[%cltr p=tusk]`
12−
13−Accepts
14−-------
15−
16−`p` is a [`++tusk`](), a list of [++twig]()s.
17−
18−Tall form
19−---------
20−
21− :~ i.p
22− i.t.p
23− i.t.t.p
24− ==
25−
26−Wide form
27−---------
28−
29− :*(i.p i.t.p i.t.t.p)
30−
31−Irregular form
32−--------------
33−
34− [i.p i.t.p i.t.t.p]
7+Regular form: *running*
358
369Examples
3710--------