diff gen/classes.cpp @ 1013:8c73ff5f69e0

Use llvm::CallSite instead of custom CallOrInvoke class.
author Frits van Bommel <fvbommel wxs.nl>
date Sat, 28 Feb 2009 22:16:52 +0100
parents 03d7c4aac654
children 6bb04dbee21f
line wrap: on
line diff
--- a/gen/classes.cpp	Sat Feb 28 19:58:30 2009 +0100
+++ b/gen/classes.cpp	Sat Feb 28 22:16:52 2009 +0100
@@ -919,7 +919,7 @@
     {
         llvm::Function* fn = LLVM_D_GetRuntimeFunction(gIR->module, "_d_allocclass");
         LLConstant* ci = DtoBitCast(tc->sym->ir.irStruct->classInfo, DtoType(ClassDeclaration::classinfo->type));
-        mem = gIR->CreateCallOrInvoke(fn, ci, ".newclass_gc_alloc")->get();
+        mem = gIR->CreateCallOrInvoke(fn, ci, ".newclass_gc_alloc").getInstruction();
         mem = DtoBitCast(mem, DtoType(tc), ".newclass_gc");
     }
 
@@ -1137,7 +1137,7 @@
     assert(funcTy->getParamType(1) == cinfo->getType());
 
     // call it
-    LLValue* ret = gIR->CreateCallOrInvoke2(func, obj, cinfo, "tmp")->get();
+    LLValue* ret = gIR->CreateCallOrInvoke2(func, obj, cinfo, "tmp").getInstruction();
 
     // cast return value
     ret = DtoBitCast(ret, DtoType(_to));
@@ -1160,7 +1160,7 @@
     tmp = DtoBitCast(tmp, funcTy->getParamType(0));
 
     // call it
-    LLValue* ret = gIR->CreateCallOrInvoke(func, tmp, "tmp")->get();
+    LLValue* ret = gIR->CreateCallOrInvoke(func, tmp, "tmp").getInstruction();
 
     // cast return value
     if (to != NULL)
@@ -1200,7 +1200,7 @@
     cinfo = DtoBitCast(cinfo, funcTy->getParamType(1));
 
     // call it
-    LLValue* ret = gIR->CreateCallOrInvoke2(func, ptr, cinfo, "tmp")->get();
+    LLValue* ret = gIR->CreateCallOrInvoke2(func, ptr, cinfo, "tmp").getInstruction();
 
     // cast return value
     ret = DtoBitCast(ret, DtoType(_to));