您好我有一个像升压图:加速图形递归模板问题
struct Vertex;
struct Edge;
typedef boost::adjacency_list<boost::vecS, boost::vecS, boost::bidirectionalS, Vertex, Edge> Graph_t;
struct Vertex {
};
struct Edge {
typedef std::vector<Graph_t::vertex_descriptor> intermediate_vertices_t;
intermediate_vertices_t intermediate_vertices;
};
的问题是,在边缘类递归模板。我需要存储一个顶点向量。
你确定你有'Graph_t'右边的模板参数吗?第四个和第五个参数是_properties_,而不是顶点和边的类本身......你必须为顶点和边集合提供一个合适的容器,'boost :: adjacency_list :: vertex_descriptor'只是指向那个类型的值容器(或多或少)。 –
你使用什么编译器。我已经编译并在VC++ 2010中运行你的代码没有任何问题 – Eugene