diff gen/dvalue.cpp @ 213:7816aafeea3c trunk

[svn r229] Updated the object.d implementation to the latest Tango. Fixed a bunch of the built-in typeinfos for arrays, they did not inherit TypeInfo_Array. Applied patch to tango/text/convert/Layout.d by fvbommel, closes #47 . Cleaned up some type code. Replaced uses of llvm::Type with LLType (a typedef), same for Value and Constant. Fixed a few cases where typeinfo for user structs could be emitted multiple times, seems to still be some cases of this :/
author lindquist
date Fri, 30 May 2008 19:32:04 +0200
parents 68a7dd38c03c
children 20446d22f832
line wrap: on
line diff
--- a/gen/dvalue.cpp	Tue May 27 22:14:24 2008 +0200
+++ b/gen/dvalue.cpp	Fri May 30 19:32:04 2008 +0200
@@ -10,7 +10,7 @@
 /////////////////////////////////////////////////////////////////////////////////////////////////
 /////////////////////////////////////////////////////////////////////////////////////////////////
 
-DVarValue::DVarValue(VarDeclaration* vd, llvm::Value* llvmValue, bool lvalue)
+DVarValue::DVarValue(VarDeclaration* vd, LLValue* llvmValue, bool lvalue)
 {
     var = vd;
     val = llvmValue;
@@ -19,7 +19,7 @@
     type = var->type;
 }
 
-DVarValue::DVarValue(Type* t, llvm::Value* lv, llvm::Value* rv)
+DVarValue::DVarValue(Type* t, LLValue* lv, LLValue* rv)
 {
     var = 0;
     val = lv;
@@ -28,7 +28,7 @@
     type = t;
 }
 
-DVarValue::DVarValue(Type* t, llvm::Value* llvmValue, bool lvalue)
+DVarValue::DVarValue(Type* t, LLValue* llvmValue, bool lvalue)
 {
     var = 0;
     val = llvmValue;
@@ -37,13 +37,13 @@
     type = t;
 }
 
-llvm::Value* DVarValue::getLVal()
+LLValue* DVarValue::getLVal()
 {
     assert(val && lval);
     return val;
 }
 
-llvm::Value* DVarValue::getRVal()
+LLValue* DVarValue::getRVal()
 {
     assert(rval || val);
     if (DtoIsPassedByRef(type)) {
@@ -63,7 +63,7 @@
 /////////////////////////////////////////////////////////////////////////////////////////////////
 /////////////////////////////////////////////////////////////////////////////////////////////////
 
-DFuncValue::DFuncValue(FuncDeclaration* fd, llvm::Value* v, llvm::Value* vt)
+DFuncValue::DFuncValue(FuncDeclaration* fd, LLValue* v, LLValue* vt)
 {
     func = fd;
     type = func->type;
@@ -72,13 +72,13 @@
     cc = (unsigned)-1;
 }
 
-llvm::Value* DFuncValue::getLVal()
+LLValue* DFuncValue::getLVal()
 {
     assert(0);
     return 0;
 }
 
-llvm::Value* DFuncValue::getRVal()
+LLValue* DFuncValue::getRVal()
 {
     assert(val);
     return val;
@@ -87,7 +87,7 @@
 /////////////////////////////////////////////////////////////////////////////////////////////////
 /////////////////////////////////////////////////////////////////////////////////////////////////
 
-llvm::Value* DConstValue::getRVal()
+LLValue* DConstValue::getRVal()
 {
     assert(c);
     return c;