summaryrefslogtreecommitdiff
path: root/lib/AsmParser/LLParser.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-12-29 21:43:58 +0000
committerChris Lattner <sabre@nondot.org>2009-12-29 21:43:58 +0000
commite80250ec84e6e3aa916a66acc507241e7bde89c9 (patch)
treed034f36f69538836ecea5b158ec334d3d01c20dc /lib/AsmParser/LLParser.h
parent3f3a0f6b498e80ffaeb83f03c8697e5d54fd9337 (diff)
downloadllvm-e80250ec84e6e3aa916a66acc507241e7bde89c9.tar.gz
llvm-e80250ec84e6e3aa916a66acc507241e7bde89c9.tar.bz2
llvm-e80250ec84e6e3aa916a66acc507241e7bde89c9.tar.xz
switch to TrackingVH instead of WeakVH, since these can never
be RAUW'd and go to null. This also gets us some sorely lacking type safety. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92272 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AsmParser/LLParser.h')
-rw-r--r--lib/AsmParser/LLParser.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/AsmParser/LLParser.h b/lib/AsmParser/LLParser.h
index eec524a5e6..7e90182052 100644
--- a/lib/AsmParser/LLParser.h
+++ b/lib/AsmParser/LLParser.h
@@ -17,8 +17,8 @@
#include "LLLexer.h"
#include "llvm/Module.h"
#include "llvm/Type.h"
-#include <map>
#include "llvm/Support/ValueHandle.h"
+#include <map>
namespace llvm {
class Module;
@@ -80,8 +80,8 @@ namespace llvm {
std::map<unsigned, std::pair<PATypeHolder, LocTy> > ForwardRefTypeIDs;
std::vector<PATypeHolder> NumberedTypes;
/// MetadataCache - This map keeps track of parsed metadata constants.
- std::map<unsigned, WeakVH> MetadataCache;
- std::map<unsigned, std::pair<WeakVH, LocTy> > ForwardRefMDNodes;
+ std::map<unsigned, TrackingVH<MDNode> > MetadataCache;
+ std::map<unsigned, std::pair<TrackingVH<MDNode>, LocTy> > ForwardRefMDNodes;
SmallVector<std::pair<unsigned, MDNode *>, 2> MDsOnInst;
struct UpRefRecord {
/// Loc - This is the location of the upref.