yggdrasil.execution.expr.walk¶
walk ¶
Pre-order tree walks over the expression AST.
Small visitor primitive every backend reaches for when it needs to collect schema-side information (referenced column names, free variables, optimisation flags) without producing a transformed tree. For rewrites prefer pattern-matching on node types directly.
walk ¶
Pre-order walk over every node in expr.
Backends use this for visitors that don't need to produce a transformed tree (schema collection, free-variable lookup, optimization checks). For tree rewrites prefer pattern-matching on node types directly.
free_columns ¶
Names of every distinct column referenced by expr.
Order is first-encounter (pre-order walk), de-duplicated. Used by the Python backend to build a value-resolution closure and by the schema emitter to advertise the predicate's input surface. Lambda parameters are bound locally and excluded.