Annotate any Tree with a description of its expression.
Annotate any Tree with a description of its expression.
In many cases this will just stringify the resulting value of an expression. But in other cases it will display parts of the expression as well as its result.
System.deconstruct is where the magic happens.
System.deconstruct is where the magic happens.
This is the high-level logic of how Claimant works. Basically, we're given a top-level Boolean expression. First we try to break that expression into sub-expressions. Each Boolean sub-expression which can't be split into smaller ones is represented by a simple claim (Claim.Simple value). For each of these we generate a label.
Then we recombine these claims using the same operations that connected their sub-expressions (e.g. AND, OR, etc.), producing a single top-level Claim.
System encapsulates the strategies used by Claimant.
Tinkers describe how to decompose Boolean expressions, and scribes describe how to label _any_ expression. Together we use them to build labels for labeled Prop values.