|
Boost Users : |
Subject: [Boost-users] Acsess boost::intrusive::list inside a map
From: Dan Bloomquist (danb_at_[hidden])
Date: 2011-03-11 14:19:14
I would like to store lists inside a map value. I can:
typedef /*boost::intrusive*/list< ClassBase > ClassList;
typedef unordered_map< Unit*, ClassList> ClassMap;
ClassList someList;
And everything works fine, But:
ClassMap someMap.
And add to access the list:
classMap[ pUnit ].push_back( aClass );
I get errors:
Thanks, Dan.
I get:
1>C:\cpp\boost_1_42_0\boost/intrusive/list.hpp(1478) : error C2248:
'boost::intrusive::list_impl<Config>::list_impl' : cannot access private
member declared in class 'boost::intrusive::list_impl<Config>'
1> with
1> [
1>
Config=boost::intrusive::listopt<boost::intrusive::detail::base_hook_traits<CmdBase,boost::intrusive::list_node_traits<void
*>,safe_link,boost::intrusive::default_tag,1>,unsigned int,true>
1> ]
1> C:\cpp\boost_1_42_0\boost/intrusive/list.hpp(117) : see
declaration of 'boost::intrusive::list_impl<Config>::list_impl'
1> with
1> [
1>
Config=boost::intrusive::listopt<boost::intrusive::detail::base_hook_traits<CmdBase,boost::intrusive::list_node_traits<void
*>,safe_link,boost::intrusive::default_tag,1>,unsigned int,true>
1> ]
1> This diagnostic occurred in the compiler generated function
'boost::intrusive::list<T>::list(const boost::intrusive::list<T> &)'
1> with
1> [
1> T=CmdBase
1> ]
1>C:\cpp\boost_1_42_0\boost/intrusive/list.hpp(1478) : error C2248:
'boost::intrusive::list_impl<Config>::list_impl' : cannot access private
member declared in class 'boost::intrusive::list_impl<Config>'
1> with
1> [
1>
Config=boost::intrusive::listopt<boost::intrusive::detail::base_hook_traits<CmdBase,boost::intrusive::list_node_traits<void
*>,safe_link,boost::intrusive::default_tag,1>,unsigned int,true>
1> ]
1> C:\cpp\boost_1_42_0\boost/intrusive/list.hpp(117) : see
declaration of 'boost::intrusive::list_impl<Config>::list_impl'
1> with
1> [
1>
Config=boost::intrusive::listopt<boost::intrusive::detail::base_hook_traits<CmdBase,boost::intrusive::list_node_traits<void
*>,safe_link,boost::intrusive::default_tag,1>,unsigned int,true>
1> ]
1> This diagnostic occurred in the compiler generated function
'boost::intrusive::list<T>::list(const boost::intrusive::list<T> &)'
1> with
1> [
1> T=CmdBase
1> ]
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