Fixed forward referenced structs.

This commit is contained in:
Tomas Lindquist Olsen
2009-04-16 20:41:27 +02:00
parent 1437bd6b7e
commit 414e58a318
2 changed files with 8 additions and 0 deletions

View File

@@ -36,6 +36,10 @@ void DtoResolveStruct(StructDeclaration* sd)
// make sure type exists
DtoType(sd->type);
// if it's a forward declaration, all bets are off. The type should be enough
if (sd->sizeok != 1)
return;
// create the IrStruct
IrStruct* irstruct = new IrStruct(sd);
sd->ir.irStruct = irstruct;