Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:53:22

0001 /* Hash function characterization.
0002  *
0003  * Copyright 2022 Joaquin M Lopez Munoz.
0004  * Distributed under the Boost Software License, Version 1.0.
0005  * (See accompanying file LICENSE_1_0.txt or copy at
0006  * http://www.boost.org/LICENSE_1_0.txt)
0007  *
0008  * See https://www.boost.org/libs/unordered for library home page.
0009  */
0010 
0011 #ifndef BOOST_UNORDERED_HASH_TRAITS_HPP
0012 #define BOOST_UNORDERED_HASH_TRAITS_HPP
0013 
0014 #include <boost/unordered/detail/type_traits.hpp>
0015 
0016 namespace boost{
0017 namespace unordered{
0018 
0019 namespace detail{
0020 
0021 template<typename Hash,typename=void>
0022 struct hash_is_avalanching_impl: std::false_type{};
0023 
0024 template<typename Hash>
0025 struct hash_is_avalanching_impl<Hash,
0026   boost::unordered::detail::void_t<typename Hash::is_avalanching> >:
0027     std::true_type{};
0028 
0029 } /* namespace detail */
0030 
0031 /* Each trait can be partially specialized by users for concrete hash functions
0032  * when actual characterization differs from default.
0033  */
0034 
0035 /* hash_is_avalanching<Hash>::value is true when the type Hash::is_avalanching
0036  * is present, false otherwise.
0037  */
0038 template<typename Hash>
0039 struct hash_is_avalanching: detail::hash_is_avalanching_impl<Hash>::type{};
0040 
0041 } /* namespace unordered */
0042 } /* namespace boost */
0043 
0044 #endif