diff options
Diffstat (limited to 'lib/CodeGen/CGBlocks.h')
-rw-r--r-- | lib/CodeGen/CGBlocks.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/CodeGen/CGBlocks.h b/lib/CodeGen/CGBlocks.h index 5d46ac78f6..05d66de3f9 100644 --- a/lib/CodeGen/CGBlocks.h +++ b/lib/CodeGen/CGBlocks.h @@ -16,6 +16,7 @@ #include "CodeGenTypes.h" #include "clang/AST/Type.h" +#include "llvm/Module.h" #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SmallVector.h" #include "clang/Basic/TargetInfo.h" @@ -38,6 +39,7 @@ namespace llvm { class TargetData; class FunctionType; class Value; + class LLVMContext; } namespace clang { @@ -63,6 +65,7 @@ class BlockModule : public BlockBase { const llvm::TargetData &TheTargetData; CodeGenTypes &Types; CodeGenModule &CGM; + llvm::LLVMContext &VMContext; ASTContext &getContext() const { return Context; } llvm::Module &getModule() const { return TheModule; } @@ -104,7 +107,7 @@ public: BlockModule(ASTContext &C, llvm::Module &M, const llvm::TargetData &TD, CodeGenTypes &T, CodeGenModule &CodeGen) : Context(C), TheModule(M), TheTargetData(TD), Types(T), - CGM(CodeGen), + CGM(CodeGen), VMContext(M.getContext()), NSConcreteGlobalBlock(0), NSConcreteStackBlock(0), BlockDescriptorType(0), GenericBlockLiteralType(0), GenericExtendedBlockLiteralType(0), BlockObjectAssign(0), BlockObjectDispose(0) { @@ -118,6 +121,9 @@ class BlockFunction : public BlockBase { CodeGenFunction &CGF; ASTContext &getContext() const; +protected: + llvm::LLVMContext &VMContext; + public: const llvm::Type *PtrToInt8Ty; struct HelperInfo { |