Fix simple struct member optimization for array cases

This commit is contained in:
drmortalwombat 2023-10-22 19:50:26 +02:00
parent f8f81f6d4c
commit 0a3ad006b7

View File

@ -1396,7 +1396,7 @@ void InterCodeGenerator::CopyStructSimple(InterCodeProcedure* proc, Expression *
Declaration* dec = vl.mType->mParams;
while (dec)
{
if (dec->mType == DT_ELEMENT && !(dec->mFlags & DTF_STATIC))
if (dec->mType == DT_ELEMENT && !(dec->mFlags & DTF_STATIC) && dec->mBase->IsSimpleType())
{
mdec = dec->mBase;
ne++;