diff -r 02c7076bf894 -r 718479989797 lemon/bfs.h --- a/lemon/bfs.h Mon May 07 08:47:38 2007 +0000 +++ b/lemon/bfs.h Mon May 07 08:48:40 2007 +0000 @@ -541,7 +541,7 @@ _reached->set(m,true); _pred->set(m,e); _dist->set(m,_curr_dist); - reached = reach || nm[m]; + reach = reach || nm[m]; } return n; } @@ -605,7 +605,7 @@ void start(Node dest) { bool reach = false; - while ( !emptyQueue() && !reach) processNextNode(dest, reach); + while ( !emptyQueue() && !reach ) processNextNode(dest, reach); } ///Executes the algorithm until a condition is met. @@ -623,7 +623,7 @@ void start(const NM &nm) { bool reach = false; - while ( !emptyQueue() && !reach) processNextNode(nm, reach); + while ( !emptyQueue() && !reach ) processNextNode(nm, reach); } ///Runs %BFS algorithm from node \c s. @@ -664,7 +664,7 @@ init(); addSource(s); start(t); - return reached(t)? _curr_dist : 0; + return reached(t) ? _curr_dist : 0; } ///@} @@ -1503,9 +1503,7 @@ /// with addSource() before using this function. void start(Node dest) { bool reach = false; - while (!emptyQueue() && !reach) { - processNextNode(dest, reach); - } + while ( !emptyQueue() && !reach ) processNextNode(dest, reach); } /// \brief Executes the algorithm until a condition is met. @@ -1521,9 +1519,7 @@ template void start(const NM &nm) { bool reach = false; - while (!emptyQueue() && !reach) { - processNextNode(nm, reach); - } + while ( !emptyQueue() && !reach ) processNextNode(nm, reach); } /// \brief Runs %BFSVisit algorithm from node \c s.