pub fn toposort_strict<G>(graph: &G) -> Result<Vec<G::V>, G::V>where G: FinGraph, G::V: Hash + Debug,
Implementation of topological sort which returns an error when it encounters a cycle.