[svn r329] Cleaned up a bunch of array code for handling special slice cases no

longer relevant.
This commit is contained in:
Tomas Lindquist Olsen 2008-06-28 05:57:16 +02:00
parent 86d299a641
commit ac3744a59d
5 changed files with 92 additions and 247 deletions

View file

@ -87,13 +87,8 @@ const LLType* DtoType(Type* t)
return DtoComplexType(t);
// pointers
case Tpointer: {
assert(t->next);
if (t->next->ty == Tvoid)
return (const LLType*)getPtrToType(LLType::Int8Ty);
else
return (const LLType*)getPtrToType(DtoType(t->next));
}
case Tpointer:
return getPtrToType(DtoType(t->next));
// arrays
case Tarray:
@ -612,6 +607,8 @@ llvm::GlobalVariable* isaGlobalVar(LLValue* v)
const LLPointerType* getPtrToType(const LLType* t)
{
if (t == LLType::VoidTy)
t = LLType::Int8Ty;
return LLPointerType::get(t, 0);
}