1 #ifndef TEST_HASH_H
2 #define TEST_HASH_H
3 
4 #include <cstddef>
5 #include <type_traits>
6 
7 template <class C>
8 class test_hash
9     : private C
10 {
11     int data_;
12 public:
13     explicit test_hash(int data = 0) : data_(data) {}
14 
15     std::size_t
16     operator()(typename std::add_lvalue_reference<const typename C::argument_type>::type x) const
17         {return C::operator()(x);}
18 
19     bool operator==(const test_hash& c) const
20         {return data_ == c.data_;}
21 };
22 
23 #endif  // TEST_HASH_H
24