1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 19:48:20 +02:00

Fixed autoprops in structs

This commit is contained in:
Brian Fiete 2020-05-19 13:19:26 -07:00
parent 01f82d1250
commit f505c9b6aa
2 changed files with 6 additions and 1 deletions

View file

@ -17532,7 +17532,7 @@ void BfModule::ProcessMethod(BfMethodInstance* methodInstance, bool isInlineDup)
else if (mCurTypeInstance->IsObject())
lookupValue = BfTypedValue(mBfIRBuilder->CreateInBoundsGEP(GetThis().mValue, 0, fieldInstance->mDataIdx), fieldInstance->mResolvedType, true);
else
lookupValue = ExtractValue(GetThis(), fieldInstance, fieldInstance->mFieldIdx);
lookupValue = ExtractValue(GetThis(), fieldInstance, fieldInstance->mDataIdx);
lookupValue = LoadOrAggregateValue(lookupValue);
CreateReturn(lookupValue.mValue);
EmitLifetimeEnds(&mCurMethodState->mHeadScope);