Fixed initialization of nested structs

This commit is contained in:
Alexey Prokhin
2011-09-13 14:47:52 +04:00
parent a0e4737c2e
commit 4879a8bc17

View File

@@ -2750,7 +2750,7 @@ DValue* StructLiteralExp::toElem(IRState* p)
#if DMDV2
else if (vd == sd->vthis) {
IF_LOG Logger::println("initializing vthis");
val = new DImValue(sd->type, DtoNestedContext(loc, sd));
val = new DImValue(Type::tvoidptr, DtoBitCast(DtoNestedContext(loc, sd), getVoidPtrType()));
}
#endif
else