Boost logo

Boost Users :

From: Ilya Chvetsov(work) (chvetsov_at_[hidden])
Date: 2003-04-22 10:02:21


sjc> Sorry, Boost.Pool does not currently support MSVC, due to that compiler's
sjc> extreme lack of template support.
It works with STLPort(www.stlport.com). On VC 6 you must define
2 helper functions
__stl_alloc_create and __stl_alloc_rebind in namespace std. Some thing
like that
namespace std
{
   template <class _Tp1, class _Tp2, class _Tp3, class _Mtx>
   inline boost::pool_allocator<_Tp2, _Tp3, _Mtx>& _STLP_CALL
                __stl_alloc_rebind(boost::pool_allocator<_Tp1, _Tp3, _Mtx>& __a, const _Tp2*)
  { return (boost::pool_allocator<_Tp2, _Tp3, _Mtx>&)(__a); }

  template <class _Tp1, class _Tp2, class _Tp3, class _Mtx>
  inline boost::pool_allocator<_Tp2, _Tp3, _Mtx> _STLP_CALL
   __stl_alloc_create(const boost::pool_allocator<_Tp1, _Tp3, _Mtx>&, const _Tp2*)
        { return boost::pool_allocator<_Tp2, _Tp3, _Mtx>(); }

}

On VC7 work without helper functions
-Ilya


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