mirror of
https://github.com/boostorg/unordered.git
synced 2025-07-29 19:07:15 +02:00
Remove C++11 constructs from hash_traits.hpp
This commit is contained in:
@ -12,7 +12,7 @@
|
||||
#define BOOST_UNORDERED_HASH_TRAITS_HPP
|
||||
|
||||
#include <boost/type_traits/make_void.hpp>
|
||||
#include <type_traits>
|
||||
#include <boost/type_traits/integral_constant.hpp>
|
||||
|
||||
namespace boost{
|
||||
namespace unordered{
|
||||
@ -20,11 +20,12 @@ namespace unordered{
|
||||
namespace detail{
|
||||
|
||||
template<typename Hash,typename=void>
|
||||
struct hash_is_avalanching_impl:std::false_type{};
|
||||
struct hash_is_avalanching_impl: boost::false_type{};
|
||||
|
||||
template<typename Hash>
|
||||
struct hash_is_avalanching_impl<Hash,void_t<typename Hash::is_avalanching>>:
|
||||
std::true_type{};
|
||||
struct hash_is_avalanching_impl<Hash,
|
||||
typename boost::make_void<typename Hash::is_avalanching>::type>:
|
||||
boost::true_type{};
|
||||
|
||||
} /* namespace detail */
|
||||
|
||||
@ -32,11 +33,11 @@ struct hash_is_avalanching_impl<Hash,void_t<typename Hash::is_avalanching>>:
|
||||
* when actual characterization differs from default.
|
||||
*/
|
||||
|
||||
/* Derived from std::true_type if the type Hash::is_avalanching is present,
|
||||
* derived from std::false_type otherwise.
|
||||
/* hash_is_avalanching<Hash>::value is true when the type Hash::is_avalanching
|
||||
* is present, false otherwise.
|
||||
*/
|
||||
template<typename Hash>
|
||||
struct hash_is_avalanching:detail::hash_is_avalanching_impl<Hash>::type{};
|
||||
struct hash_is_avalanching: detail::hash_is_avalanching_impl<Hash>::type{};
|
||||
|
||||
} /* namespace unordered */
|
||||
} /* namespace boost */
|
||||
|
@ -139,7 +139,7 @@ build_foa erase_if ;
|
||||
build_foa scary_tests ;
|
||||
build_foa init_type_insert_tests ;
|
||||
|
||||
run unordered/hash_is_avalanching_test.cpp : : : $(CPP11) ;
|
||||
run unordered/hash_is_avalanching_test.cpp ;
|
||||
|
||||
run exception/constructor_exception_tests.cpp : : : $(CPP11) <define>BOOST_UNORDERED_FOA_TESTS : foa_constructor_exception_tests ;
|
||||
run exception/copy_exception_tests.cpp : : : $(CPP11) <define>BOOST_UNORDERED_FOA_TESTS : foa_copy_exception_tests ;
|
||||
|
Reference in New Issue
Block a user