diff options
author | Chris Lattner <sabre@nondot.org> | 2011-08-12 17:43:31 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2011-08-12 17:43:31 +0000 |
commit | c1c20114a401e503c07d68c47e0728bb063f35c8 (patch) | |
tree | 581edc6714b4095a78edee43be8aecaf8a8d88ba /lib/CodeGen/CGBlocks.cpp | |
parent | f80b0db7b131ce5bc9451b21d0555bd686e348f1 (diff) |
switch clang to use the new-new way of creating llvm::StructType's.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137472 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGBlocks.cpp')
-rw-r--r-- | lib/CodeGen/CGBlocks.cpp | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/lib/CodeGen/CGBlocks.cpp b/lib/CodeGen/CGBlocks.cpp index af4f26c427..b795ef1bef 100644 --- a/lib/CodeGen/CGBlocks.cpp +++ b/lib/CodeGen/CGBlocks.cpp @@ -681,8 +681,8 @@ llvm::Type *CodeGenModule::getBlockDescriptorType() { // const char *layout; // reserved // }; BlockDescriptorType = - llvm::StructType::createNamed("struct.__block_descriptor", - UnsignedLongTy, UnsignedLongTy, NULL); + llvm::StructType::create("struct.__block_descriptor", + UnsignedLongTy, UnsignedLongTy, NULL); // Now form a pointer to that. BlockDescriptorType = llvm::PointerType::getUnqual(BlockDescriptorType); @@ -703,13 +703,9 @@ llvm::Type *CodeGenModule::getGenericBlockLiteralType() { // struct __block_descriptor *__descriptor; // }; GenericBlockLiteralType = - llvm::StructType::createNamed("struct.__block_literal_generic", - VoidPtrTy, - IntTy, - IntTy, - VoidPtrTy, - BlockDescPtrTy, - NULL); + llvm::StructType::create("struct.__block_literal_generic", + VoidPtrTy, IntTy, IntTy, VoidPtrTy, + BlockDescPtrTy, NULL); return GenericBlockLiteralType; } @@ -1664,8 +1660,8 @@ llvm::Type *CodeGenFunction::BuildByRefType(const VarDecl *D) { SmallVector<llvm::Type *, 8> types; llvm::StructType *ByRefType = - llvm::StructType::createNamed(getLLVMContext(), - "struct.__block_byref_" + D->getNameAsString()); + llvm::StructType::create(getLLVMContext(), + "struct.__block_byref_" + D->getNameAsString()); // void *__isa; types.push_back(Int8PtrTy); |