|
Boost Users : |
From: Peter Dimov (pdimov_at_[hidden])
Date: 2007-04-12 17:30:16
Stephen Torri wrote:
> On Thu, 2007-04-12 at 23:50 +0300, Peter Dimov wrote:
>> MSVC 8 says that you're using an uninitialized 'node' variable here.
>> Is this intended?
>
> The code needs to be changed to creating and fully initializing a node
> before adding it. If you read the rest of the function you will notice
> that I add the unitialized Vertex, grab a handle to it and then fill
> it in.
I see; so the error in property_map is caused by something else then. Here's
the complete call stack at the time I get an assertion from the standard
library... hopefully it can give you some clues as to why it attempts to
create an invalid vector iterator. I can't help you more since I know
nothing about the Graph library, maybe someone more familiar with it will
take a look?
> testbed8.exe!std::_Vector_const_iterator<enum
> boost::default_color_type,std::allocator<enum boost::default_color_type>
> >::operator+=(int _Off=20) Line 148 + 0x50 bytes C++
testbed8.exe!std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>::operator+=(int _Off=20) Line 363 C++
testbed8.exe!std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>::operator+(int _Off=20) Line 369 + 0xc bytes C++
testbed8.exe!boost::iterator_property_map<std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>,boost::adj_list_vertex_property_map<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,unsigned long,unsigned
long const &,enum boost::vertex_index_t>,enum boost::default_color_type,enum
boost::default_color_type &>::operator[](void * v=0x00c76338) Line 351 +
0x67 bytes C++
testbed8.exe!boost::put<boost::iterator_property_map<std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>,boost::adj_list_vertex_property_map<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,unsigned long,unsigned
long const &,enum boost::vertex_index_t>,enum boost::default_color_type,enum
boost::default_color_type &>,enum boost::default_color_type &,void *,enum
boost::default_color_type>(const boost::put_get_helper<enum
boost::default_color_type
&,boost::iterator_property_map<std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>,boost::adj_list_vertex_property_map<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,unsigned long,unsigned
long const &,enum boost::vertex_index_t>,enum boost::default_color_type,enum
boost::default_color_type &> > & pa={...}, void * k=0x00c76338, const
boost::default_color_type & v=white_color) Line 321 + 0xc bytes C++
testbed8.exe!boost::depth_first_search<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > >
>,boost::iterator_property_map<std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>,boost::adj_list_vertex_property_map<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,unsigned long,unsigned
long const &,enum boost::vertex_index_t>,enum boost::default_color_type,enum
boost::default_color_type &> >(const
boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> & g={...},
boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > > vis={...},
boost::iterator_property_map<std::_Vector_iterator<enum
boost::default_color_type,std::allocator<enum boost::default_color_type>
>,boost::adj_list_vertex_property_map<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,unsigned long,unsigned
long const &,enum boost::vertex_index_t>,enum boost::default_color_type,enum
boost::default_color_type &> color={...}, void * start_vertex=0x00c761c8)
Line 197 + 0x26 bytes C++
testbed8.exe!boost::detail::dfs_dispatch<boost::detail::error_property_not_found>::apply<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,void
*,boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > >
>,boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > >,enum
boost::graph_visitor_t,boost::bgl_named_params<int,boost::buffer_param_t,boost::no_property>
>(const
boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> & g={...},
boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > > vis={...}, void * start_vertex=0x00c761c8,
const
boost::bgl_named_params<boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > >,enum
boost::graph_visitor_t,boost::bgl_named_params<int,boost::buffer_param_t,boost::no_property>
> & params={...}, boost::detail::error_property_not_found __formal={...})
Line 254 + 0xa6 bytes C++
testbed8.exe!boost::depth_first_search<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS>,boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > >,enum
boost::graph_visitor_t,boost::bgl_named_params<int,boost::buffer_param_t,boost::no_property>
>(const
boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> & g={...}, const
boost::bgl_named_params<boost::topo_sort_visitor<std::back_insert_iterator<std::vector<void
*,std::allocator<void *> > > >,enum
boost::graph_visitor_t,boost::bgl_named_params<int,boost::buffer_param_t,boost::no_property>
> & params={...}) Line 337 + 0xf8 bytes C++
testbed8.exe!boost::topological_sort<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> const
,std::back_insert_iterator<std::vector<void *,std::allocator<void *> >
>,int,boost::buffer_param_t,boost::no_property>(const
boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> & g={...},
std::back_insert_iterator<std::vector<void *,std::allocator<void *> > >
result={...}, const
boost::bgl_named_params<int,boost::buffer_param_t,boost::no_property> &
params={...}) Line 64 + 0x77 bytes C++
testbed8.exe!boost::topological_sort<boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> const
,std::back_insert_iterator<std::vector<void *,std::allocator<void *> > >
>(const
boost::adjacency_list<boost::setS,boost::setS,boost::directedS,boost::property<enum
boost::vertex_index_t,unsigned long,boost::property<enum
boost::vertex_name_t,boost::shared_ptr<Component>,boost::no_property>
>,boost::no_property,boost::no_property,boost::listS> & g={...},
std::back_insert_iterator<std::vector<void *,std::allocator<void *> > >
result={...}) Line 71 + 0x31 bytes C++
testbed8.exe!main(int __formal=1, int __formal=1) Line 256 + 0x43 bytes
C++
testbed8.exe!__tmainCRTStartup() Line 318 + 0x19 bytes C
testbed8.exe!mainCRTStartup() Line 187 C
kernel32.dll!7c816fd7()
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net