Fixed crashes when compiling interpret test.

This commit is contained in:
Alexey Prokhin 2010-12-17 12:55:28 +03:00
parent f5f5c2e1f9
commit eccd26ac93
4 changed files with 15 additions and 6 deletions

View file

@ -75,7 +75,7 @@ void DtoArrayInit(Loc& loc, DValue* array, DValue* value)
LLValue* val;
// give slices and complex values storage (and thus an address to pass)
if (value->isSlice())
if (value->isSlice() || value->type->ty == Tdelegate)
{
val = DtoAlloca(value->getType(), ".tmpparam");
DVarValue lval(value->getType(), val);