Documentation ¶
Index ¶
Constants ¶
const ( SameTree TreeIdentity = false NewTree TreeIdentity = true VisitChildren VisitRule = true SkipChildren VisitRule = false )
Variables ¶
This section is empty.
Functions ¶
func BottomUp ¶
BottomUp rewrites an operator tree from the bottom up. BottomUp applies a transformation function to the given operator tree from the bottom up. Each callback [f] returns a TreeIdentity that is aggregated into a final output indicating whether the operator tree was changed.
func TopDown ¶
TopDown applies a transformation function to the given operator tree from the bottom up. = Each callback [f] returns a TreeIdentity that is aggregated into a final output indicating whether the operator tree was changed. The callback also returns a VisitRule that signals whether the children of this operator should be visited or not
Types ¶
type BreakableFunc ¶
type TreeIdentity ¶
type TreeIdentity bool
TreeIdentity tracks modifications to node and expression trees. Only return SameTree when it is acceptable to return the original input and discard the returned result as a performance improvement.