Expand description
CRUDUI expression AST nodes (expressions.md §4, JS ConditionParser.ts parity).
to_value() emits the canonical fixture shape, byte-matching the JS reference
field names: Ternary{condition,trueValue,falseValue}, Binary{operator,left, right}, Unary{operator,operand}, In{negated,value,list}, Path{relative, levelsUp,segments}, Literal{valueType,value}, Group{expression}. The
JS/Go position field is DELIBERATELY ABSENT — Rust holds no position, so the
4-language AST contract excludes it; including it would break cross-language
fixture equality.
Enums§
- Literal
Value - A literal’s value kind plus its concrete value (number kept as int or float so the fixture’s integer literals stay integers when serialized).
- Node
- An expression AST node (expressions.md §4).
- Path
Segment - A single path segment: identifier (field name), wildcard (
*), or index (numeric array index). The index value serializes as a number to match the JS reference segment shape ({type:'index', value:number}).