1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 12:32:20 +02:00

Aggregate fix for nullable casting

This commit is contained in:
Brian Fiete 2025-03-22 17:01:18 -04:00
parent c7da3e15f9
commit 65a3bb2196

View file

@ -14087,6 +14087,7 @@ BfIRValue BfModule::CastToValue(BfAstNode* srcNode, BfTypedValue typedVal, BfTyp
if (!typedVal.IsAddr())
{
auto srcAlloca = CreateAllocaInst(fromNullableType);
typedVal = LoadOrAggregateValue(typedVal);
mBfIRBuilder->CreateStore(typedVal.mValue, srcAlloca);
srcPtr = srcAlloca;
}