mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-02-28 17:43:14 +01:00
[svn r140] did a lot of the work towards being able to pass multiple modules on the command line. not complete yet though
This commit is contained in:
@@ -40,7 +40,7 @@ IRState::IRState()
|
||||
ir.state = this;
|
||||
}
|
||||
|
||||
IRFunction* IRState::func()
|
||||
IrFunction* IRState::func()
|
||||
{
|
||||
assert(!functions.empty() && "Function stack is empty!");
|
||||
return functions.back();
|
||||
@@ -64,7 +64,7 @@ llvm::Instruction* IRState::topallocapoint()
|
||||
return functions.back()->allocapoint;
|
||||
}
|
||||
|
||||
IRStruct* IRState::topstruct()
|
||||
IrStruct* IRState::topstruct()
|
||||
{
|
||||
assert(!structs.empty() && "Struct vector is empty!");
|
||||
return structs.back();
|
||||
@@ -101,32 +101,6 @@ bool IRState::scopereturned()
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
IRStruct::IRStruct(Type* t)
|
||||
: recty((t->llvmType != NULL) ? *t->llvmType : llvm::OpaqueType::get())
|
||||
{
|
||||
type = t;
|
||||
defined = false;
|
||||
constinited = false;
|
||||
interfaceInfosTy = NULL;
|
||||
interfaceInfos = NULL;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
IRFinally::IRFinally()
|
||||
{
|
||||
bb = 0;
|
||||
retbb = 0;
|
||||
}
|
||||
|
||||
IRFinally::IRFinally(llvm::BasicBlock* b, llvm::BasicBlock* rb)
|
||||
{
|
||||
bb = b;
|
||||
retbb = rb;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
LLVMBuilder* IRBuilderHelper::operator->()
|
||||
{
|
||||
LLVMBuilder& b = state->scope().builder;
|
||||
@@ -136,20 +110,6 @@ LLVMBuilder* IRBuilderHelper::operator->()
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
IRFunction::IRFunction(FuncDeclaration* fd)
|
||||
{
|
||||
decl = fd;
|
||||
Type* t = DtoDType(fd->type);
|
||||
assert(t->ty == Tfunction);
|
||||
type = (TypeFunction*)t;
|
||||
func = NULL;
|
||||
allocapoint = NULL;
|
||||
finallyretval = NULL;
|
||||
defined = false;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
IRExp::IRExp()
|
||||
{
|
||||
e1 = e2 = NULL;
|
||||
@@ -162,11 +122,3 @@ IRExp::IRExp(Expression* l, Expression* r, DValue* val)
|
||||
e2 = r;
|
||||
v = val;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
IRGlobal::IRGlobal(VarDeclaration* v) :
|
||||
type(llvm::OpaqueType::get())
|
||||
{
|
||||
var = v;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user