comparison gen/tollvm.cpp @ 1024:9167d492cbc2

Abstracted more (most) ABI details out of the normal codegen.
author Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
date Tue, 03 Mar 2009 02:51:21 +0100
parents 18ad5601dff7
children 32ead42679d1
comparison
equal deleted inserted replaced
1023:ca191c141cec 1024:9167d492cbc2
225 225
226 const LLStructType* DtoDelegateType(Type* t) 226 const LLStructType* DtoDelegateType(Type* t)
227 { 227 {
228 assert(t->ty == Tdelegate); 228 assert(t->ty == Tdelegate);
229 const LLType* i8ptr = getVoidPtrType(); 229 const LLType* i8ptr = getVoidPtrType();
230 const LLType* func = DtoFunctionType(t->nextOf(), NULL, i8ptr); 230 const LLType* func = DtoFunctionType(t->nextOf(), NULL, Type::tvoid->pointerTo());
231 const LLType* funcptr = getPtrToType(func); 231 const LLType* funcptr = getPtrToType(func);
232 return LLStructType::get(i8ptr, funcptr, NULL); 232 return LLStructType::get(i8ptr, funcptr, NULL);
233 } 233 }
234 234
235 ////////////////////////////////////////////////////////////////////////////////////////// 235 //////////////////////////////////////////////////////////////////////////////////////////