mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 03:28:20 +02:00
BfConstType_Agg fix for padded FixValues
This commit is contained in:
parent
4cee66b1f8
commit
7c0293620a
2 changed files with 44 additions and 3 deletions
|
@ -886,6 +886,10 @@ void BeIRCodeGen::Read(BeValue*& beValue)
|
|||
|
||||
auto constStruct = mBeModule->mOwnedValues.Alloc<BeStructConstant>();
|
||||
constStruct->mType = type;
|
||||
|
||||
if (type->IsStruct())
|
||||
FixValues((BeStructType*)type, values);
|
||||
|
||||
for (int i = 0; i < (int)values.size(); i++)
|
||||
{
|
||||
auto val = values[i];
|
||||
|
@ -934,9 +938,6 @@ void BeIRCodeGen::Read(BeValue*& beValue)
|
|||
constStruct->mMemberValues.Add(constant);
|
||||
}
|
||||
|
||||
if (type->IsStruct())
|
||||
FixValues((BeStructType*)type, constStruct->mMemberValues);
|
||||
|
||||
beValue = constStruct;
|
||||
|
||||
BE_MEM_END("ParamType_Const_Array");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue