run cargo fmt
diff --git a/src/algo/mod.rs b/src/algo/mod.rs
index e072d79..c9c5a46 100644
--- a/src/algo/mod.rs
+++ b/src/algo/mod.rs
@@ -797,9 +797,10 @@
///
/// Always treats the input graph as if undirected.
pub fn is_bipartite_undirected<G, N, VM>(g: G, start: N) -> bool
- where G: GraphRef + Visitable<NodeId=N, Map=VM> + IntoNeighbors<NodeId=N>,
- N: Copy + PartialEq + std::fmt::Debug,
- VM: VisitMap<N>
+where
+ G: GraphRef + Visitable<NodeId = N, Map = VM> + IntoNeighbors<NodeId = N>,
+ N: Copy + PartialEq + std::fmt::Debug,
+ VM: VisitMap<N>,
{
let mut red = g.visit_map();
red.visit(start);
@@ -826,9 +827,15 @@
//hasn't been visited yet
match (is_red, is_blue) {
- (true, false) => { blue.visit(neighbour); },
- (false, true) => { red.visit(neighbour); },
- (_, _) => { panic!("Invariant doesn't hold"); }
+ (true, false) => {
+ blue.visit(neighbour);
+ }
+ (false, true) => {
+ red.visit(neighbour);
+ }
+ (_, _) => {
+ panic!("Invariant doesn't hold");
+ }
}
stack.push_back(neighbour);
diff --git a/tests/graph.rs b/tests/graph.rs
index a33977a..6a1522a 100644
--- a/tests/graph.rs
+++ b/tests/graph.rs
@@ -9,8 +9,8 @@
use petgraph as pg;
use petgraph::algo::{
- dominators, has_path_connecting, is_cyclic_undirected, is_isomorphic_matching, is_bipartite_undirected,
- min_spanning_tree,
+ dominators, has_path_connecting, is_bipartite_undirected, is_cyclic_undirected,
+ is_isomorphic_matching, min_spanning_tree,
};
use petgraph::graph::node_index as n;