17 #include "my_config.h"
18 #include <gtest/gtest.h>
20 #if defined(__GNUC__) && __GNUC__ > 3
21 #include <tr1/unordered_map>
22 #elif defined(__WIN__)
24 #elif defined(__SUNPRO_CC)
27 #error "Don't know how to implement hash_map"
31 template<
typename K,
typename T>
34 #if defined(__GNUC__) && __GNUC__ > 3
35 typedef std::tr1::unordered_map<K, T> Type;
36 #elif defined(__WIN__)
37 typedef stdext::hash_map<K, T> Type;
38 #elif defined(__SUNPRO_CC)
39 typedef std::hash_map<K, T> Type;
47 for (
int ix= 0; ix < 10; ++ix)
53 EXPECT_TRUE(0 == intmap.count(42));
54 EXPECT_TRUE(intmap.end() == intmap.find(42));