Merge branch 'master' into merge-2.061-2

This commit is contained in:
kai
2013-02-02 15:27:51 +01:00
6 changed files with 45 additions and 43 deletions

View File

@@ -57,10 +57,8 @@ IrTypeBasic* IrTypeBasic::get(Type* dt)
LLType* IrTypeBasic::getComplexType(llvm::LLVMContext& ctx, LLType* type)
{
llvm::SmallVector<LLType*, 2> types;
types.push_back(type);
types.push_back(type);
return llvm::StructType::get(ctx, types);
llvm::Type *types[] = { type, type };
return llvm::StructType::get(ctx, types, false);
}
//////////////////////////////////////////////////////////////////////////////
@@ -257,10 +255,8 @@ IrTypeArray* IrTypeArray::get(Type* dt)
// just as for pointers.
if (!dt->irtype)
{
llvm::SmallVector<LLType*, 2> types;
types.push_back(DtoSize_t());
types.push_back(llvm::PointerType::get(elemType, 0));
LLType* at = llvm::StructType::get(llvm::getGlobalContext(), types/*, t->toChars()*/);
llvm::Type *types[] = { DtoSize_t(), llvm::PointerType::get(elemType, 0) };
LLType* at = llvm::StructType::get(llvm::getGlobalContext(), types, false);
dt->irtype = new IrTypeArray(dt, at);
}