
Hi, trying to use fast_pool_allocator in Boost 1.35 fails with MSVC 9.0; it worked well with MSVC 8.0. The following code fragment shows the error: #include <boost/multi_index_container.hpp> #include <boost/multi_index/indexed_by.hpp> #include <boost/multi_index/sequenced_index.hpp> #include <boost/multi_index/identity.hpp> #include <boost/pool/pool_alloc.hpp> using namespace boost; using namespace boost::multi_index; typedef multi_index_container<int, indexed_by<sequenced<> >, fast_pool_allocator<int> > IntSet; IntSet s; Below you can see the compiler error message. Am I doing something wrong? (From what I've seen digging through the code, it seems to me that the allocator gets rebound from int to void, which does not work for fast_pool_allocator.) Thanks, Filip C:\lib\Boost-1_35_0\include\boost-1_35\boost/pool/pool_alloc.hpp(130) : error C2182: 'reference' : illegal use of type 'void' C:\lib\Boost-1_35_0\include\boost-1_35\boost/detail/allocator_utilities.hpp(149) : see reference to class template instantiation 'boost::fast_pool_allocator<T,UserAllocator,Mutex,NextSize>' being compiled with [ T=void, UserAllocator=boost::default_user_allocator_new_delete, Mutex=boost::details::pool::default_mutex, NextSize=32 ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/detail/allocator_utilities.hpp(158) : see reference to class template instantiation 'boost::detail::allocator::rebinder<Allocator>::result<Type>' being compiled with [ Allocator=boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>, Type=boost::multi_index::detail::sequenced_index_node_impl<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/mpl/eval_if.hpp(63) : see reference to class template instantiation 'boost::detail::allocator::compliant_allocator_rebind_to<Allocator,Type>' being compiled with [ Allocator=boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>, Type=boost::multi_index::detail::sequenced_index_node_impl<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/detail/allocator_utilities.hpp(170) : see reference to class template instantiation 'boost::mpl::eval_if_c<C,F1,F2>' being compiled with [ C=false, F1=boost::detail::allocator::partial_std_allocator_rebind_to<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>,boost::multi_index::detail::sequenced_index_node_impl<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>>>, F2=boost::detail::allocator::compliant_allocator_rebind_to<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>,boost::multi_index::detail::sequenced_index_node_impl<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/multi_index/detail/seq_index_node.hpp(36) : see reference to class template instantiation 'boost::detail::allocator::rebind_to<Allocator,Type>' being compiled with [ Allocator=boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>, Type=boost::multi_index::detail::sequenced_index_node_impl<boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/multi_index/detail/seq_index_node.hpp(148) : see reference to class template instantiation 'boost::multi_index::detail::sequenced_index_node_impl<Allocator>' being compiled with [ Allocator=boost::fast_pool_allocator<void,boost::default_user_allocator_new_delete,boost::details::pool::default_mutex,32> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/multi_index/detail/seq_index_node.hpp(162) : see reference to class template instantiation 'boost::multi_index::detail::sequenced_index_node_trampoline<Super>' being compiled with [ Super=boost::multi_index::detail::index_node_base<int,boost::fast_pool_allocator<int>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/multi_index/sequenced_index.hpp(95) : see reference to class template instantiation 'boost::multi_index::detail::sequenced_index_node<Super>' being compiled with [ Super=boost::multi_index::detail::index_node_base<int,boost::fast_pool_allocator<int>> ] C:\lib\Boost-1_35_0\include\boost-1_35\boost/multi_index_container.hpp(86) : see reference to class template instantiation 'boost::multi_index::detail::sequenced_index<SuperMeta,TagList>' being compiled with [ SuperMeta=boost::multi_index::detail::nth_layer<1,int,boost::multi_index::indexed_by<boost::multi_index::sequenced<>>,boost::fast_pool_allocator<int>>, TagList=boost::mpl::vector0<boost::mpl::na> ] .\relink.cpp(97) : see reference to class template instantiation 'boost::multi_index::multi_index_container<Value,IndexSpecifierList,Allocator>' being compiled with [ Value=int, IndexSpecifierList=boost::multi_index::indexed_by<boost::multi_index::sequenced<>>, Allocator=boost::fast_pool_allocator<int> ]