mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-02-09 16:33:14 +01:00
More changes to std::vector usage.
Replace with std::vector with static array, llvm::SmallVector or add code to reserve space.
This commit is contained in:
@@ -172,10 +172,11 @@ static LLFunction* build_module_reference_and_ctor(LLConstant* moduleinfo)
|
||||
|
||||
// provide the default initializer
|
||||
LLStructType* modulerefTy = DtoModuleReferenceType();
|
||||
std::vector<LLConstant*> mrefvalues;
|
||||
mrefvalues.push_back(LLConstant::getNullValue(modulerefTy->getContainedType(0)));
|
||||
mrefvalues.push_back(llvm::ConstantExpr::getBitCast(moduleinfo, modulerefTy->getContainedType(1)));
|
||||
LLConstant* thismrefinit = LLConstantStruct::get(modulerefTy, mrefvalues);
|
||||
LLConstant* mrefvalues[] = {
|
||||
LLConstant::getNullValue(modulerefTy->getContainedType(0)),
|
||||
llvm::ConstantExpr::getBitCast(moduleinfo, modulerefTy->getContainedType(1))
|
||||
};
|
||||
LLConstant* thismrefinit = LLConstantStruct::get(modulerefTy, llvm::ArrayRef<LLConstant*>(mrefvalues));
|
||||
|
||||
// create the ModuleReference node for this module
|
||||
std::string thismrefname = "_D";
|
||||
|
||||
Reference in New Issue
Block a user