diff options
Diffstat (limited to 'boost/iostreams/filter/lzma.hpp')
-rw-r--r-- | boost/iostreams/filter/lzma.hpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/boost/iostreams/filter/lzma.hpp b/boost/iostreams/filter/lzma.hpp index f15f6794a7..94cd2b3b54 100644 --- a/boost/iostreams/filter/lzma.hpp +++ b/boost/iostreams/filter/lzma.hpp @@ -112,8 +112,12 @@ namespace detail { template<typename Alloc> struct lzma_allocator_traits { #ifndef BOOST_NO_STD_ALLOCATOR +#if defined(BOOST_NO_CXX11_ALLOCATOR) typedef typename Alloc::template rebind<char>::other type; #else + typedef typename std::allocator_traits<Alloc>::template rebind_alloc<char> type; +#endif +#else typedef std::allocator<char> type; #endif }; @@ -123,7 +127,11 @@ template< typename Alloc, BOOST_DEDUCED_TYPENAME lzma_allocator_traits<Alloc>::type > struct lzma_allocator : private Base { private: +#if defined(BOOST_NO_CXX11_ALLOCATOR) || defined(BOOST_NO_STD_ALLOCATOR) typedef typename Base::size_type size_type; +#else + typedef typename std::allocator_traits<Base>::size_type size_type; +#endif public: BOOST_STATIC_CONSTANT(bool, custom = (!is_same<std::allocator<char>, Base>::value)); |