Module Topological.Make
Functor providing topological iterators over a graph.
Parameters
Signature
val fold : (G.V.t -> 'a -> 'a) -> G.t -> 'a -> 'afold action g seedallows iterating over the graphgin topological order.action node accuis called repeatedly, wherenodeis the node being visited, andaccuis the result of theaction's previous invocation, if any, andseedotherwise. Ifgcontains cycles, the order is unspecified inside the cycles and every node in the cycles will be presented exactly once.Not tail-recursive. Complexity: O(V+E)