Include vector into these two files to ensure that specializations like
authorVikram S. Adve <vadve@cs.uiuc.edu>
Fri, 25 Jul 2003 14:06:13 +0000 (14:06 +0000)
committerVikram S. Adve <vadve@cs.uiuc.edu>
Fri, 25 Jul 2003 14:06:13 +0000 (14:06 +0000)
stl_bvector.h are correctly included into *anything* that includes hash_map
or hash_set.  ext/hash_map includes stl_vector.h directly and leaves
out the specializations, causing truly nasty bugs due to inconsistent
versions of vector<> being used for vector<bool> in different files.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7303 91177308-0d34-0410-b5e6-96231b3b80d8

include/Support/hash_map
include/Support/hash_set

index ce4c42f6ab9ff5be35e73d309d1a01c2c05bfb4a..72d8bf36ba548d8c21056c18e2f641fe9c0e82ed 100644 (file)
@@ -42,6 +42,10 @@ using HASH_NAMESPACE::hash_map;
 using HASH_NAMESPACE::hash_multimap;
 using HASH_NAMESPACE::hash;
 
+/* Include vector because ext/hash_map includes stl_vector.h and leaves
+   out specializations like stl_bvector.h, causing link conflicts. */
+#include <vector>
+
 #include <Support/HashExtras.h>
 
 #endif
index 045083c8cd54ebfc95e4fbaaf87ff921307031b4..46e75d8b94f6e522d1ba4d1679f0da2f1949b406 100644 (file)
 using HASH_NAMESPACE::hash_set;
 using HASH_NAMESPACE::hash;
 
+/* Include vector because ext/hash_set includes stl_vector.h and leaves
+   out specializations like stl_bvector.h, causing link conflicts. */
+#include <vector>
+
 #include <Support/HashExtras.h>
 
 #endif