Changeset 324:fafece417795 in lemon for test/graph_utils_test.cc
- Timestamp:
- 10/08/08 13:25:57 (16 years ago)
- Branch:
- 1.0
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
test/graph_utils_test.cc
r220 r324 36 36 { 37 37 Digraph digraph; 38 typename Digraph::template NodeMap<int> nodes(digraph); 39 std::vector<Node> invNodes; 38 40 for (int i = 0; i < 10; ++i) { 39 digraph.addNode(); 40 } 41 DescriptorMap<Digraph, Node> nodes(digraph); 42 typename DescriptorMap<Digraph, Node>::InverseMap invNodes(nodes); 41 invNodes.push_back(digraph.addNode()); 42 nodes[invNodes.back()]=invNodes.size()-1; 43 } 43 44 for (int i = 0; i < 100; ++i) { 44 45 int src = rnd[invNodes.size()]; … … 47 48 } 48 49 typename Digraph::template ArcMap<bool> found(digraph, false); 49 DescriptorMap<Digraph, Arc> arcs(digraph);50 50 for (NodeIt src(digraph); src != INVALID; ++src) { 51 51 for (NodeIt trg(digraph); trg != INVALID; ++trg) { … … 111 111 TEMPLATE_GRAPH_TYPEDEFS(Graph); 112 112 Graph graph; 113 typename Graph::template NodeMap<int> nodes(graph); 114 std::vector<Node> invNodes; 113 115 for (int i = 0; i < 10; ++i) { 114 graph.addNode(); 115 } 116 DescriptorMap<Graph, Node> nodes(graph); 117 typename DescriptorMap<Graph, Node>::InverseMap invNodes(nodes); 116 invNodes.push_back(graph.addNode()); 117 nodes[invNodes.back()]=invNodes.size()-1; 118 } 118 119 for (int i = 0; i < 100; ++i) { 119 120 int src = rnd[invNodes.size()]; … … 122 123 } 123 124 typename Graph::template EdgeMap<int> found(graph, 0); 124 DescriptorMap<Graph, Edge> edges(graph);125 125 for (NodeIt src(graph); src != INVALID; ++src) { 126 126 for (NodeIt trg(graph); trg != INVALID; ++trg) {
Note: See TracChangeset
for help on using the changeset viewer.