Expand description
The Transform expression language: the tokenizer, the parser and the evaluator (docs/specs/SPEC_DRONE_GENERAL_AUTOMATION_2026_11_11.md Β§3.9).
StructsΒ§
- Eval π
- Parser π
- State π
- What one nodeβs evaluation carries between elements: the budget it has spent.
EnumsΒ§
ConstantsΒ§
- MAX_
EVAL_ πDEPTH - How deep an expression tree may be before evaluation stops: a chain such as
1 + 1 + ...is not nested in the source but is deep in the tree. - MAX_
EXPRESSION_ πBYTES - An expressionβs source may be at most this long. The grammar is small, and
a bound keeps the tokenizer and parser work finite; the size of a
matchespattern is bounded separately, where the pattern is compiled. - MAX_
NESTING_ πDEPTH - How deeply a source may nest
(,[,!and-. The parser is recursive, so a source nested further is an expression error rather than a stack overflow. - MAX_
OPERATORS π - How many binary operators one expression may hold. A chain is built by a loop, so it is neither nested in the source nor limited by the nesting depth, but dropping its tree recurses once per node.
FunctionsΒ§
- arithmetic π
- as_list π
- binary π
- charge π
- One unit of the evaluation budget; the total may not pass
MAX_OPERATIONS. - cmp_
same_ πclass - compare π
- contains π
- equal π
- eval_at π
- function_
arity π - How many arguments each function name takes; anything else is unknown.
- in_set π
- lookup_
path π - negate π
- number_
at π - operator_
at π - parse_
object_ πpath - A dotted path with no operators, for
existsover an object. - parse_
opt π - parse_
or π - text_at π
- tokenize π
- value_
class π - The type a sort key must share with every other key before ordering is defined; ordering across types is an expression error.