on master help sign in
minor changes to runes in reference
commit48f43e0a764c7e0070e89ed2c49e2572133164cb authorjoshuareagan <joshuareagan@gmail.com> dateTue 9 Oct 2018, 18:48 (8 years ago) parentae5275f
10 files changed+33−24
docs/reference/rune.udon+1−1 docs/reference/rune/constants/cold.udon+5−4 docs/reference/rune/constants/text.udon+5−2 docs/reference/rune/dot/ket.udon+4−4 docs/reference/rune/dot/lus.udon+1−1 docs/reference/rune/dot/tar.udon+4−3 docs/reference/rune/dot/tis.udon+1−1 docs/reference/rune/limb/limb.udon+4−4 docs/reference/rune/limb/wing.udon+7−3 docs/reference/rune/sig/zap.udon+1−1
docs/reference/rune.udon+1−1
@@ -6,7 +6,7 @@
66
77# Runes
88
9−### _...and how to form Hoon expressions_
9+### Forming Expressions of Hoon
1010
1111;div(class "book")
1212
docs/reference/rune/constants/cold.udon+5−4
@@ -17,13 +17,13 @@ A cold (fixed) atom `q` with aura `p`.
1717
1818### Syntax
1919
20−Irregular: any warm atom [(`%sand`)](../warm/) form, prefixed with `%`.
20+Irregular: any [warm atom](../warm/) form, prefixed with `%`.
2121
2222Irregular: e.g., `%hi`. Character constraints: `a-z`
2323lowercase to start, `a-z` or `0-9` thereafter, with infix
2424hyphens (`hep`), "kebab-case."
2525
26−Irregular: `~`, `@n`, null (`0`).
26+Irregular: `~`.
2727
2828### Examples
2929
@@ -35,6 +35,7 @@ We can see the contrast with warm atoms by using the compiler parser function, `
3535
3636> (ream '\'hi\'')
3737[%sand p=%t q=26.984]
38−```
3938
40−Cold atoms all have the aura `@tas`. (Hence the `p=%tas` in the parsed result of `%12`.)
39+> (ream '%12')
40+[%rock p=%ud q=12]
41+```
docs/reference/rune/constants/text.udon+5−2
@@ -1,11 +1,11 @@
11:- :~ navhome/'/docs/'
22 navuptwo/'true'
33 sort/'3'
4− title/'Text /w Interpolation'
4+ title/'Strings'
55 ==
66;>
77
8−# Text with Interpolation
8+# Strings with Interpolation
99
1010`[%knit p=(list (each @t hoon))]`: text string with interpolation.
1111
@@ -25,6 +25,9 @@ Irregular: `"abc{(weld "lmnop" "xyz")}defg"`.
2525
2626> "abc{(weld "lmnop" "xyz")}defg"
2727"abclmnopxyzdefg"
28+
29+> (ream '"abcdefg"')
30+[%knit p=~[97 98 99 100 101 102 103]]
2831```
2932
3033### Examples
docs/reference/rune/dot/ket.udon+4−4
@@ -6,7 +6,7 @@
66
77# `.^ "dotket"`
88
9−`[%dtkt p=spec q=hoon]`: load from the Arvo namespace with Nock `11`.
9+`[%dtkt p=spec q=hoon]`: load from the Arvo namespace with a fake Nock instruction: 'Nock `12`''.
1010
1111## Produces
1212
@@ -14,8 +14,8 @@ The noun `q`, cast to the type `p`.
1414
1515## Discussion
1616
17−Nock has no `11` instruction, of course. But the virtual Nock
18−used to run userspace code does. Nock `11` loads from a
17+Nock has no `12` instruction! But the virtual Nock
18+used to run userspace code does. Nock `12` loads from a
1919typed immutable namespace defined by its virtual context.
2020
2121Ordinarily a Hoon expression has access to no information but whatever can be found in the subject. The one exception is with the `.^` rune. It essentially allows you to request information from one of the Arvo vanes (modules).
@@ -26,7 +26,7 @@ In principle `.^` takes two subexpressions, but in practice `q` is often given i
2626
2727## Examples
2828
29−In the dojo we can ask Clay for a listing of the files at our current path, `%`:
29+In the dojo we can ask Clay -- the Arvo filesystem -- for a listing of the files at our current path, `%`:
3030
3131```
3232> .^(arch %cy %)
docs/reference/rune/dot/lus.udon+1−1
@@ -7,7 +7,7 @@
77
88# `.+ "dotlus"`
99
10−`[%dtls p=atom]`: increment an atom with Nock `4`.
10+`[%dtls p=hoon]`: increment an atom with Nock `4`.
1111
1212## Produces
1313
docs/reference/rune/dot/tar.udon+4−3
@@ -19,11 +19,12 @@ Regular: *2-fixed*.
1919
2020## Discussion
2121
22+`.*(p q)` is used to run Nock formula `p` on the subject `q` from within Hoon.
23+
2224Keep in mind that `p` and `q` can be arbitrary Hoon expressions, as long as they evaluate to the appropriate nouns for Nock evaluation.
2325
24−Note that `.*` ("dottar") can be used to bypass the type system,
25−though its product contains no type information. It's
26−perfectly possible to use Hoon as a typeless language.
26+Note also that `.*` ("dottar") can be used to bypass the type system. It's
27+therefore possible to use Hoon as a typeless language.
2728
2829## Examples
2930
docs/reference/rune/dot/tis.udon+1−1
@@ -23,7 +23,7 @@ Irregular: `=(a b)` is `.=(a b)`.
2323
2424The test for equality includes a type check. Either the type of `p` must nest under the type of `q`, or _vice versa_. Otherwise the result is a crash.
2525
26−Like Nock equality, `.=` ("dottis") tests if two nouns are the same,
26+Like Nock equality, `.=` ("dottis") tests whether two nouns are the same,
2727ignoring invisible pointer structure. Because in a conventional
2828noun implementation each noun has a lazy short hash, comparisons
2929are fast unless the hash needs to be computed, or we are comparing
docs/reference/rune/limb/limb.udon+4−4
@@ -5,15 +5,15 @@
55 ==
66;>
77
8−# Limbs
8+# Limb Expressions
99
10−Attribute of subject.
10+A limb is an attribute of subject.
1111
1212### Produces
1313
14−If a limb resolves to a leg of the subject, the leg is produced. If a limb resolves to an arm by way of an arm name, then the arm is evaluated with its parent core as the subject and the result of that evaluation is produced.
14+There are two kinds of limbs: arms and legs. An *arm* is a computation of some core. A *leg* is a piece of data in the subject.
1515
16−An arm is a Nock formula in the battery of a core. A leg is any other piece of data in the subject.
16+If a limb expression resolves to a leg, the leg is produced. If a limb expression resolves to an arm -- in particular, by way of an arm name -- then the arm is computed with its parent core as the subject. The result of that computation is produced.
1717
1818### Syntax
1919
docs/reference/rune/limb/wing.udon+7−3
@@ -5,13 +5,15 @@
55 ==
66;>
77
8−# Wings
8+# Wing Expressions
99
10−`[%wing p=(list limb)]`; a limb search path into the subject.
10+`[%wing p=(list limb)]`
11+
12+A wing is a limb search path into the subject.
1113
1214### Produces
1315
14−A wing is a list of limbs (including a trivial list of one limb). The limbs are resolved to values in the subject in succession, and the result of the last limb resolution is the value produced by the wing.
16+A wing is a list of limbs (including a trivial list of one limb). The limbs are resolved in succession. The result of the last limb resolution is the value produced by the wing expression.
1517
1618### Syntax
1719
@@ -36,8 +38,10 @@ is the same limb as `+`, `..b` is the same wing as `+1.foo`.
3638
3739```
3840~zod:dojo> =a [fod=3 bat=[baz=1 moo=2]]
41+
3942~zod:dojo> bat.a
4043[baz=1 moo=2]
44+
4145~zod:dojo> moo.bat.a
42462
4347```
docs/reference/rune/sig/zap.udon+1−1
@@ -1,7 +1,7 @@
11:- :~ navhome/'/docs/'
22 next/'true'
33 sort/'6'
4− title/'~? "sigzap"'
4+ title/'~! "sigzap"'
55 ==
66;>
77