# HG changeset patch # User marci # Date 1074252125 0 # Node ID 8b29d935f1a6c37249900f73e11a5be232ec0540 # Parent dd19ef4d7ba42fde2ef7df48277517026adee593 make_invalid() diff -r dd19ef4d7ba4 -r 8b29d935f1a6 src/work/marci_max_flow.hh --- a/src/work/marci_max_flow.hh Fri Jan 16 11:21:47 2004 +0000 +++ b/src/work/marci_max_flow.hh Fri Jan 16 11:22:05 2004 +0000 @@ -44,6 +44,7 @@ } } bool is_valid() { return sym.is_valid(); } + void make_invalid() { sym.make_invalid(); } void augment(T a) { if (resG->G.a_node(sym)==resG->G.tail(sym)) { resG->flow.put(sym, resG->flow.get(sym)+a); @@ -81,8 +82,8 @@ int id(const node_iterator& v) { return G.id(v); } - node_iterator invalid_node() { return G.invalid_node(); } - res_edge_it invalid_edge() { res_edge_it n; n.sym=G.invalid_sym_edge(); return n; } + //node_iterator invalid_node() { return G.invalid_node(); } + //res_edge_it invalid_edge() { res_edge_it n; n.sym=G.invalid_sym_edge(); return n; } }; @@ -127,8 +128,6 @@ bfs_queue.push(res_graph.first_out_edge(s)); typedef node_property_vector reached_type; - //reached_type reached(res_graph); - //for(graph_traits::each_node_iterator i=res_graph.first_node(); i.is_valid(); ++i) { reached.put(i, false); } reached_type reached(res_graph, false); reached.put(s, true); @@ -137,7 +136,9 @@ typedef node_property_vector::edge_iterator> pred_type; pred_type pred(res_graph); - pred.put(s, res_graph.invalid_edge()); + graph_traits::edge_iterator a; + a.make_invalid(); + pred.put(s, a); typedef node_property_vector free_type; free_type free(res_graph);