Module Wto_utils.Make
Parameters
Signature
val map : (N.t -> bool -> 'a) -> N.t Wto.partition -> 'a Wto.partitionmap f wto applies f to every element of wto while conserving the w.t.o. structure. The second argument of f is true if the argument of f is a head.
val iter : (N.t -> bool -> unit) -> N.t Wto.partition -> unititer f wto applies f to every element of wto. The second argument of f is true if the argument of f is a head.
val is_head_of : N.t Wto.partition -> N.t -> N.t -> boolhead_of wto h n returns whether n is inside the component of head h. h must be a head. Returns true also if n = h. Complexity: linear in the number of nodes.
val depth : N.t Wto.partition -> intMaximum number of heads among all nodes, i.e. maximum number of nested components.