Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/boost/locale/detail/allocator_traits.hpp was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 //
0002 // Copyright (c) 2024 Alexander Grund
0003 //
0004 // Distributed under the Boost Software License, Version 1.0.
0005 // https://www.boost.org/LICENSE_1_0.txt
0006 
0007 #ifndef BOOST_LOCALE_DETAIL_ALLOCATOR_TRAITS_HPP_INCLUDED
0008 #define BOOST_LOCALE_DETAIL_ALLOCATOR_TRAITS_HPP_INCLUDED
0009 
0010 #include <boost/locale/config.hpp>
0011 #include <memory>
0012 #include <type_traits>
0013 
0014 /// \cond INTERNAL
0015 namespace boost { namespace locale { namespace conv { namespace detail {
0016     template<class Alloc, typename T>
0017     using rebind_alloc = typename std::allocator_traits<Alloc>::template rebind_alloc<T>;
0018 
0019     template<class Alloc, typename T, typename Result = void>
0020     using enable_if_allocator_for =
0021       typename std::enable_if<std::is_same<typename Alloc::value_type, T>::value, Result>::type;
0022     template<class Alloc, typename T, class Alloc2, typename T2, typename Result = void>
0023     using enable_if_allocator_for2 = typename std::enable_if<std::is_same<typename Alloc::value_type, T>::value
0024                                                                && std::is_same<typename Alloc2::value_type, T2>::value,
0025                                                              Result>::type;
0026 }}}} // namespace boost::locale::conv::detail
0027 
0028 /// \endcond
0029 
0030 #endif