diff options
Diffstat (limited to 'src/google/protobuf/stubs/hash.h')
-rwxr-xr-x | src/google/protobuf/stubs/hash.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/google/protobuf/stubs/hash.h b/src/google/protobuf/stubs/hash.h index 58334322..bbd8ee65 100755 --- a/src/google/protobuf/stubs/hash.h +++ b/src/google/protobuf/stubs/hash.h @@ -214,6 +214,8 @@ class hash_map : public std::map<Key, Data, HashFcn, Alloc> { hash_map(int a = 0, const HashFcn& b = HashFcn(), const EqualKey& c = EqualKey(), const Alloc& d = Alloc()) : BaseClass(b, d) {} + + HashFcn hash_function() const { return HashFcn(); } }; template <typename Key, @@ -222,6 +224,8 @@ template <typename Key, class hash_set : public std::set<Key, HashFcn> { public: hash_set(int = 0) {} + + HashFcn hash_function() const { return HashFcn(); } }; #elif defined(_MSC_VER) && !defined(_STLPORT_VERSION) @@ -257,6 +261,8 @@ class hash_map hash_map(int a = 0, const HashFcn& b = HashFcn(), const EqualKey& c = EqualKey(), const Alloc& d = Alloc()) : BaseClass(a, b, c, d) {} + + HashFcn hash_function() const { return HashFcn(); } }; template <typename Key, typename HashFcn = hash<Key>, @@ -266,6 +272,8 @@ class hash_set Key, HashFcn, EqualKey> { public: hash_set(int = 0) {} + + HashFcn hash_function() const { return HashFcn(); } }; #else @@ -315,6 +323,8 @@ class hash_map hash_map(int a = 0, const HashFcn& b = HashFcn(), const EqualKey& c = EqualKey(), const Alloc& d = Alloc()) : BaseClass(a, b, c, d) {} + + HashFcn hash_function() const { return HashFcn(); } }; template <typename Key, typename HashFcn = hash<Key>, @@ -324,6 +334,8 @@ class hash_set Key, HashFcn, EqualKey> { public: hash_set(int = 0) {} + + HashFcn hash_function() const { return HashFcn(); } }; #endif // !GOOGLE_PROTOBUF_MISSING_HASH |