mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-02-28 09:33:27 +01:00
[svn r104] TONS OF FIXES.
Split up declaration, constant initializer gen and definition for globals, structs, classes and functions. Improved ClassInfo support (not complete), not in vtable yet. Fixed a bunch of forward reference problems. Much more. Major commit! :)
This commit is contained in:
@@ -24,6 +24,8 @@
|
||||
namespace llvm {
|
||||
class Value;
|
||||
}
|
||||
struct IRFunction;
|
||||
struct IRGlobal;
|
||||
|
||||
struct Expression;
|
||||
struct Statement;
|
||||
@@ -128,8 +130,6 @@ struct Declaration : Dsymbol
|
||||
Declaration *isDeclaration() { return this; }
|
||||
|
||||
virtual void toObjFile(); // compile to .obj file
|
||||
|
||||
bool llvmTouched;
|
||||
};
|
||||
|
||||
/**************************************************************/
|
||||
@@ -263,6 +263,8 @@ struct VarDeclaration : Declaration
|
||||
int llvmFieldIndex;
|
||||
size_t llvmFieldIndexOffset;
|
||||
bool llvmNeedsStorage;
|
||||
llvm::Constant* llvmConstInit;
|
||||
IRGlobal* llvmIRGlobal;
|
||||
};
|
||||
|
||||
/**************************************************************/
|
||||
@@ -293,6 +295,8 @@ struct ClassInfoDeclaration : VarDeclaration
|
||||
void emitComment(Scope *sc);
|
||||
|
||||
Symbol *toSymbol();
|
||||
|
||||
ClassInfoDeclaration* isClassInfoDeclaration() { return this; }
|
||||
};
|
||||
|
||||
struct ModuleInfoDeclaration : VarDeclaration
|
||||
@@ -558,6 +562,7 @@ struct FuncDeclaration : Declaration
|
||||
llvm::Value* llvmArgPtr;
|
||||
llvm::Constant* llvmDwarfSubProgram;
|
||||
bool llvmRunTimeHack;
|
||||
IRFunction* llvmIRFunc;
|
||||
};
|
||||
|
||||
struct FuncAliasDeclaration : FuncDeclaration
|
||||
|
||||
Reference in New Issue
Block a user