@@ -14,16 +14,11 @@
14If `p` produces yes, `%.y`, then `q`. If `p` produces no, `%.n`, then `r`.
14If `p` produces yes, `%.y`, then `q`. If `p` produces no, `%.n`, then `r`.
15If `p` is not a boolean, compiler yells at you.
15If `p` is not a boolean, compiler yells at you.
17−The subjects of `q` and `r` are constrained to match any
17+### Type inference
18−pattern-matching algebra in `p`. The analysis, which is
19−conservative, understands any combination of [`?=` ("wuttis")](../tis/),
20−[`?&` ("wutpad")](../pad/), [`?|` ("wutbar")](../bar/), and
21−[`?!` ("wutzap")](../zap/), and reduces the subject appropriately when
19+The subject types of `q` and `r` are constrained to match any pattern-matching algebra in `p`. The analysis, which is conservative, understands any combination of [`?=`](../tis/), [`?&`](../pad/), [`?|`](../bar/), and [`?!`](../zap/), and infers the type of the subject appropriately when compiling.
24−If test analysis reveals that either branch is not taken,
21+If test analysis reveals that either branch is never taken, or if `p` is not a boolean, compilation fails. An untaken branch is indicated with `mint-lost`.
25−or if `p` is not a boolean, compilation fails. However,
26−an untaken branch can be indicated with the `%lost` hoon.
@@ -36,7 +31,7 @@ and includes the expected inference. For instance,
36if you write `?&(a b)`, `b` is only executed if `a` is
31if you write `?&(a b)`, `b` is only executed if `a` is
37positive, and compiled with that assumption.
32positive, and compiled with that assumption.
39−Note also that all other branching hoons reduce to `?:`.
34+Note also that all other branching expressions reduce to `?:`.
41## Examples
36## Examples