summaryrefslogtreecommitdiff
path: root/src/tr1_hash_map.h
blob: 1ff7c8e57007dd649155bb0721d57627b07561fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#pragma once 

// detection and fallback for unordered_map in C++0x
#ifdef __cplusplus
   #ifdef __GNUC__
   #if __GNUC__ >= 4 && __GNUC_MINOR__ >= 3
      #include <unordered_map>
      #define tr1_hash_map std::unordered_map
      #define tr1_hash_map_ismap 0
   #else
      #include <map>
      #define tr1_hash_map std::map
      #define tr1_hash_map_ismap 1
   #endif
   #else
      #include <map>
      #define tr1_hash_map std::map
      #define tr1_hash_map_ismap 1
   #endif
#endif