on master help sign in
fixes #870
cd13397David Kerschner
tutorials/arvo/gall.md+4−11
@@ -153,12 +153,7 @@ Here's a skeleton example of an implementation:
153::
153::
154++ on-load
154++ on-load
155 |= =old-state=vase
155 |= =old-state=vase
156− =/ old-state !<(@ old-state-vase)
156+ `this(state !<(@ old-state-vase))
157− ?~ old-state
158− ~& %prep-lost
159− `this
160− ~& %prep-found
161− `this(state old-state)
162::
157::
163++ on-poke
158++ on-poke
164 |= [=mark =vase]
159 |= [=mark =vase]
@@ -366,14 +361,12 @@ represent a value which has a type that isn't known at compile time. A
366vase has three operations:
361vase has three operations:
367
362
368- `!>` is a unary rune that lifts a statically typed value to a
363- `!>` is a unary rune that lifts a statically typed value to a
369− dynamically-typed `vase`. For example, `!>('hi')` gives `[[%atom %t ~]
364+ dynamically-typed `vase`. For example, `!>('hi')` gives `[#t/@t q=26.984]`.
370− 26.984']`, which has type `[type *]`.
371
365
372- `!<` is a binary rune that takes a mold and a dynamically typed `vase`
366- `!<` is a binary rune that takes a mold and a dynamically typed `vase`
373 and reduces it to a statically typed value. If the `vase` does not in
367 and reduces it to a statically typed value. If the `vase` does not in
374− fact have the type of the mold you give it, then it produces `~`, else
368+ fact have the type of the mold you give it, then it nest-fails, else
375− it produces `[~ value]`. For example, `!<(@t !>('hi'))` produces `[~
369+ it produces `value`. For example, `!<(@t !>('hi'))` produces `'hi'` while `!<(^ !>('hi'))` causes a nest fail..
376− 'hi']` while `!<(^ !>('hi'))` produces `~`.
377
370
378- The compiler takes text and converts it to a `vase` of the compiled
371- The compiler takes text and converts it to a `vase` of the compiled
379 code. Agents shouldn't need this directly, but Gall uses this to
372 code. Agents shouldn't need this directly, but Gall uses this to