1 //===-- Support/hash_map - "Portable" wrapper around hash_map ---*- C++ -*-===//
3 // This file provides a wrapper around the mysterious <hash_map> header file
4 // that seems to move around between GCC releases into and out of namespaces at
5 // will. #including this header will cause hash_map to be available in the
8 //===----------------------------------------------------------------------===//
10 #ifndef SUPPORT_HASH_MAP
11 #define SUPPORT_HASH_MAP
13 // Compiler Support Matrix
15 // Version Namespace Header File
17 // 3.0.4 std ext/hash_map
18 // 3.1 __gnu_cxx ext/hash_map
21 #include "Config/config.h"
23 #ifdef HAVE_GNU_EXT_HASH_MAP
25 #include <ext/hash_map>
26 #define HASH_NAMESPACE __gnu_cxx
30 #ifdef HAVE_STD_EXT_HASH_MAP
31 #include <ext/hash_map>
32 #define HASH_NAMESPACE std
36 #define HASH_NAMESPACE
41 using HASH_NAMESPACE::hash_map;
42 using HASH_NAMESPACE::hash_multimap;
43 using HASH_NAMESPACE::hash;
45 /* Include vector because ext/hash_map includes stl_vector.h and leaves
46 out specializations like stl_bvector.h, causing link conflicts. */
49 #include <Support/HashExtras.h>