
On Mon, 31 Aug 2009, Ryan W. Frenz wrote:
I am attempting to upgrade to boost 1.40 and have found an issue with cuthill_mckee_ordering.hpp. The following code demonstrates the issue.
#include <boost/graph/adjacency_matrix.hpp> #include <boost/graph/cuthill_mckee_ordering.hpp>
int main() { typedef boost::property<boost::vertex_name_t, std::string> VertexProperty; typedef boost::adjacency_matrix<boost::undirectedS, VertexProperty> MyGraph; typedef boost::graph_traits<MyGraph>::vertex_descriptor Vertex;
MyGraph graph(0);
// Fill graph with nodes, etc....
// Perform reverse cuthill mckee... std::vector<Vertex> inv_perm(boost::num_vertices(graph)); { boost::cuthill_mckee_ordering(graph, inv_perm.rbegin()); // 'has_no_vertices' error... // do stuff with ordered graph... }
return 0; }
This code builds cleanly against 1.36 (my previous version) but fails when built against 1.40 with the following:
....boost/graph/cuthill_mckee_ordering.hpp(172): 'has_no_vertices': identifer not found
Looking at the code, the function boost::cuthill_mckee_ordering is calling has_no_vertices (with no specified namespace). has_no_vertices (in graph_utility.hpp) lives in the boost::graph namespace. Changing the line to graph::has_no_vertices fixes the compiler error.
Is this possibly a bug in 1.40 or am I doing something wrong?
This looks like a bug; do you have a small, self-contained example that would demonstrate the problem? Could you please file it in Trac so we can have a record of it and work on it? Thank you. -- Jeremiah Willcock