Mercurial > projects > ldc
diff gen/runtime.cpp @ 157:5c17f81fc1c1 trunk
[svn r173] moved IR state previously stored in Type into IrType and a Type->IrType map; fixes #7
author | ChristianK |
---|---|
date | Thu, 01 May 2008 13:32:08 +0200 |
parents | 44a95ac7368a |
children | a8cd9bc1021a |
line wrap: on
line diff
--- a/gen/runtime.cpp Thu May 01 13:05:53 2008 +0200 +++ b/gen/runtime.cpp Thu May 01 13:32:08 2008 +0200 @@ -15,6 +15,7 @@ #include "gen/runtime.h" #include "gen/logger.h" #include "gen/tollvm.h" +#include "gen/irstate.h" static llvm::Module* M = NULL; static bool runtime_failed = false; @@ -188,9 +189,9 @@ const llvm::Type* stringTy = rt_array(byteTy); const llvm::Type* wstringTy = rt_array(shortTy); const llvm::Type* dstringTy = rt_array(intTy); - const llvm::Type* objectTy = rt_ptr(ClassDeclaration::object->type->llvmType->get()); - const llvm::Type* classInfoTy = rt_ptr(ClassDeclaration::classinfo->type->llvmType->get()); - const llvm::Type* typeInfoTy = rt_ptr(Type::typeinfo->type->llvmType->get()); + const llvm::Type* objectTy = rt_ptr(gIR->irType[ClassDeclaration::object->type].type->get()); + const llvm::Type* classInfoTy = rt_ptr(gIR->irType[ClassDeclaration::classinfo->type].type->get()); + const llvm::Type* typeInfoTy = rt_ptr(gIR->irType[Type::typeinfo->type].type->get()); const llvm::Type* aaTy = rt_ptr(llvm::OpaqueType::get()); /////////////////////////////////////////////////////////////////////////////////////