Switch CGDebugInfo type cache to using an AssertingVH.
llvm-svn: 82321
diff --git a/clang/lib/CodeGen/CGDebugInfo.h b/clang/lib/CodeGen/CGDebugInfo.h
index 3308a6b..d0f0731 100644
--- a/clang/lib/CodeGen/CGDebugInfo.h
+++ b/clang/lib/CodeGen/CGDebugInfo.h
@@ -18,10 +18,15 @@
#include "clang/Basic/SourceLocation.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/Analysis/DebugInfo.h"
+#include "llvm/Support/ValueHandle.h"
#include <map>
#include "CGBuilder.h"
+namespace llvm {
+ class MDNode;
+}
+
namespace clang {
class VarDecl;
class ObjCInterfaceDecl;
@@ -44,7 +49,7 @@
/// TypeCache - Cache of previously constructed Types.
// FIXME: Eliminate this map. Be careful of iterator invalidation.
- std::map<void *, llvm::DIType> TypeCache;
+ std::map<void *, llvm::AssertingVH<llvm::MDNode> > TypeCache;
bool BlockLiteralGenericSet;
llvm::DIType BlockLiteralGeneric;