From 5e9cd434234a36089daeee915f1dc02b96947fba Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Mon, 28 Dec 2009 08:30:43 +0000 Subject: [PATCH] snip one more #include from Metadata.h git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92214 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Metadata.h | 5 ++--- lib/CodeGen/MachineInstr.cpp | 1 + lib/VMCore/Metadata.cpp | 4 ++++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/include/llvm/Metadata.h b/include/llvm/Metadata.h index e8b27d6c5b7..28f9356ba9f 100644 --- a/include/llvm/Metadata.h +++ b/include/llvm/Metadata.h @@ -17,7 +17,6 @@ #define LLVM_METADATA_H #include "llvm/Value.h" -#include "llvm/Type.h" #include "llvm/ADT/FoldingSet.h" #include "llvm/ADT/ilist_node.h" @@ -25,6 +24,7 @@ namespace llvm { class Constant; class Instruction; class LLVMContext; +class Module; class MetadataContextImpl; template class SmallVectorImpl; template class SmallPtrSet; @@ -55,8 +55,7 @@ class MDString : public MetadataBase { StringRef Str; protected: - explicit MDString(LLVMContext &C, StringRef S) - : MetadataBase(Type::getMetadataTy(C), Value::MDStringVal), Str(S) {} + explicit MDString(LLVMContext &C, StringRef S); public: static MDString *get(LLVMContext &Context, StringRef Str); diff --git a/lib/CodeGen/MachineInstr.cpp b/lib/CodeGen/MachineInstr.cpp index f919510525f..a761c2daa96 100644 --- a/lib/CodeGen/MachineInstr.cpp +++ b/lib/CodeGen/MachineInstr.cpp @@ -15,6 +15,7 @@ #include "llvm/Constants.h" #include "llvm/Function.h" #include "llvm/InlineAsm.h" +#include "llvm/Type.h" #include "llvm/Value.h" #include "llvm/Assembly/Writer.h" #include "llvm/CodeGen/MachineFunction.h" diff --git a/lib/VMCore/Metadata.cpp b/lib/VMCore/Metadata.cpp index f1361c4fe38..8565b9e2459 100644 --- a/lib/VMCore/Metadata.cpp +++ b/lib/VMCore/Metadata.cpp @@ -29,6 +29,10 @@ using namespace llvm; //===----------------------------------------------------------------------===// // MDString implementation. // + +MDString::MDString(LLVMContext &C, StringRef S) + : MetadataBase(Type::getMetadataTy(C), Value::MDStringVal), Str(S) {} + MDString *MDString::get(LLVMContext &Context, StringRef Str) { LLVMContextImpl *pImpl = Context.pImpl; StringMapEntry &Entry =