Problem
compressed_sparse_row_graph.hpp contains four public add_vertex / add_vertices functions that were part of an old interface deliberately removed in 2009:
Vertex add_vertex(compressed_sparse_row_graph& g);
Vertex add_vertex(compressed_sparse_row_graph& g, const vertex_bundled& p); // directed
Vertex add_vertex(compressed_sparse_row_graph& g, const vertex_bundled& p); // bidirectional
Vertex add_vertices(vertices_size_type count, compressed_sparse_row_graph& g); // directed
These are not in the HTML documentation, not tested in test/csr_graph_test.cpp, and not used anywhere in BGL internally.
Meanwhile, the documentation states: "The CSR graph is immutable after construction. You cannot call add_vertex()."
The related add_edges() and add_edges_sorted() functions are documented and tested.
History
- 2005 (
0e2f4646): Jeremiah Willcock added add_vertex(), add_vertices(), and add_edges() as "incremental construction functions." All three were documented and tested.
- 2009 (
b2636ec3, "Removed old CSR interface; fixes #3135 "): add_vertex() and add_vertices() were removed from documentation and tests, but the implementations were left in the header.
- 2012 (
849d1538): add_edges() was separately removed from bidirectional CSR as "broken and not documented."
Question
Should add_vertex() / add_vertices() be tested and documented, or removed? Probably removed I guess, but I find it odd the implementation was never actually removed.
Problem
compressed_sparse_row_graph.hppcontains four publicadd_vertex/add_verticesfunctions that were part of an old interface deliberately removed in 2009:These are not in the HTML documentation, not tested in
test/csr_graph_test.cpp, and not used anywhere in BGL internally.Meanwhile, the documentation states: "The CSR graph is immutable after construction. You cannot call
add_vertex()."The related
add_edges()andadd_edges_sorted()functions are documented and tested.History
0e2f4646): Jeremiah Willcock addedadd_vertex(),add_vertices(), andadd_edges()as "incremental construction functions." All three were documented and tested.b2636ec3, "Removed old CSR interface; fixes #3135 "):add_vertex()andadd_vertices()were removed from documentation and tests, but the implementations were left in the header.849d1538):add_edges()was separately removed from bidirectional CSR as "broken and not documented."Question
Should
add_vertex()/add_vertices()be tested and documented, or removed? Probably removed I guess, but I find it odd the implementation was never actually removed.