Converts a fold φ into one that replaces tree values: every tree node
will be replaced with the intermediate value of the fold at the node.
For example, to convert the descendantCount fold, that folds a tree into a
tree total descendant count to one where each node value is the
node total descendant count:
Converts a fold
φinto one that replaces tree values: every tree node will be replaced with the intermediate value of the fold at the node.For example, to convert the
descendantCountfold, that folds a tree into a tree total descendant count to one where each node value is the node total descendant count: