on master help sign in
change aura explanation to utf-32
6892c94Tinnus Napbus
content/docs/hoon/reference/auras.md+10−1
@@ -16,7 +16,7 @@ You can learn more about auras in [Hoon school](/docs/hoon/hoon-school/atoms-aur
16Aura Meaning Example Literal Syntax
16Aura Meaning Example Literal Syntax
17-------------------------------------------------------------------------
17-------------------------------------------------------------------------
18@ empty aura
18@ empty aura
19−@c Unicode codepoint ~-~45fed
19+@c UTF-32 ~-~45fed
20@d date
20@d date
21 @da absolute date ~2018.5.14..22.31.46..1435
21 @da absolute date ~2018.5.14..22.31.46..1435
22 @dr relative date (ie, timespan) ~h5.m30.s12
22 @dr relative date (ie, timespan) ~h5.m30.s12
@@ -66,23 +66,30 @@ two, starting from A.
66
66
67A given aura nests under any aura whose name is a substring or extension of the
67A given aura nests under any aura whose name is a substring or extension of the
68given aura:
68given aura:
69+
69```
70```
70> :- (~(nest ut [%atom %ud ~]) | [%atom %u ~])
71> :- (~(nest ut [%atom %ud ~]) | [%atom %u ~])
71 (~(nest ut [%atom %ud ~]) | [%atom %udx ~])
72 (~(nest ut [%atom %ud ~]) | [%atom %udx ~])
72[%.y %.y]
73[%.y %.y]
73```
74```
75+
74but does not nest "sideways":
76but does not nest "sideways":
77+
75```
78```
76> (~(nest ut [%atom %ud ~]) | [%atom %ux ~])
79> (~(nest ut [%atom %ud ~]) | [%atom %ux ~])
77%.n
80%.n
78```
81```
82+
79We call auras "soft types" since this nesting behavior can be ignored. Auras are
83We call auras "soft types" since this nesting behavior can be ignored. Auras are
80non-coercive, but conversions may have to go via the empty aura, e.g.
84non-coercive, but conversions may have to go via the empty aura, e.g.
85+
81```
86```
82> ^-(@ud ^-(@ 'foo'))
87> ^-(@ud ^-(@ 'foo'))
837.303.014
887.303.014
84```
89```
90+
85This is implicitly done by the irregular form of `^-`.
91This is implicitly done by the irregular form of `^-`.
92+
86```
93```
87> `@ud`'foo'
94> `@ud`'foo'
887.303.014
957.303.014
@@ -91,8 +98,10 @@ This is implicitly done by the irregular form of `^-`.
91### Bunting
98### Bunting
92
99
93The bunt value for all auras is 0 except for `@da`.
100The bunt value for all auras is 0 except for `@da`.
101+
94```
102```
95> *@da
103> *@da
96~2000.1.1
104~2000.1.1
97```
105```
106+
98A bunt value of 0 is helpful when working with loobeans.
107A bunt value of 0 is helpful when working with loobeans.
content/docs/hoon/reference/rune/constants.md+1−1
@@ -146,7 +146,7 @@ A table of examples:
146Aura Meaning Example Literal Syntax
146Aura Meaning Example Literal Syntax
147-------------------------------------------------------------------------
147-------------------------------------------------------------------------
148@ empty aura
148@ empty aura
149−@c Unicode codepoint ~-~45fed
149+@c UTF-32 ~-~45fed
150@d date
150@d date
151 @da absolute date ~2018.5.14..22.31.46..1435
151 @da absolute date ~2018.5.14..22.31.46..1435
152 @dr relative date (ie, timespan) ~h5.m30.s12
152 @dr relative date (ie, timespan) ~h5.m30.s12