2
0
mirror of https://github.com/boostorg/graph.git synced 2026-01-27 19:02:12 +00:00

some bug fixes from Rich

[SVN r11641]
This commit is contained in:
Jeremy Siek
2001-11-09 14:41:02 +00:00
parent 90cc4a95b4
commit 04bc75cd40

View File

@@ -98,11 +98,18 @@ namespace boost {
subgraph(vertices_size_type n,
const graph_property_type& p = graph_property_type())
: m_graph(n, p), m_parent(0), m_edge_counter(0), m_global_vertex(n)
{ }
{
std::vector<vertex_descriptor>::iterator b = m_global_vertex.begin();
std::vector<vertex_descriptor>::iterator e = m_global_vertex.end();
for(vertices_size_type i = 0; b != e; ++b)
*b = i++;
}
// copy constructor
subgraph(const subgraph& x)
: m_graph(x.m_graph), m_parent(x.m_parent), m_edge_counter(x.m_edge_counter)
: m_graph(x.m_graph), m_parent(x.m_parent),
m_edge_counter(x.m_edge_counter),
m_global_vertex(x.m_global_vertex)
{
// Do a deep copy
for (std::list< subgraph<Graph>*>::iterator i = x.m_children.begin();