Push the context through StructType::get.

Requires LLVM >= 78258. Also remove old #if's.
This commit is contained in:
Benjamin Kramer 2009-08-06 01:47:39 +02:00
parent de0d74dc68
commit 977fa551ee
22 changed files with 57 additions and 70 deletions

View file

@ -142,7 +142,7 @@ void RTTIBuilder::push_funcptr(FuncDeclaration* fd, Type* castto)
void RTTIBuilder::finalize(IrGlobal* tid)
{
// create the inititalizer
LLConstant* tiInit = LLConstantStruct::get(&inits[0], inits.size(), false);
LLConstant* tiInit = LLConstantStruct::get(gIR->context(), &inits[0], inits.size(), false);
// refine global type
llvm::cast<llvm::OpaqueType>(tid->type.get())->refineAbstractTypeTo(tiInit->getType());
@ -154,5 +154,5 @@ void RTTIBuilder::finalize(IrGlobal* tid)
LLConstant* RTTIBuilder::get_constant()
{
// just return the inititalizer
return LLConstantStruct::get(&inits[0], inits.size(), false);
return LLConstantStruct::get(gIR->context(), &inits[0], inits.size(), false);
}