mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
AddPhiIncoming valueless fix
This commit is contained in:
parent
d1134ebfb8
commit
a2f5517e5c
1 changed files with 4 additions and 2 deletions
|
@ -23235,8 +23235,10 @@ bool BfExprEvaluator::PerformBinaryOperation_NullCoalesce(BfTokenNode* opToken,
|
|||
else
|
||||
{
|
||||
auto phi = mModule->mBfIRBuilder->CreatePhi(mModule->mBfIRBuilder->MapType(leftValue.mType), 2);
|
||||
mModule->mBfIRBuilder->AddPhiIncoming(phi, leftValue.mValue, endLhsBB);
|
||||
mModule->mBfIRBuilder->AddPhiIncoming(phi, rightValue.mValue, endRhsBB);
|
||||
if (!leftValue.mType->IsValuelessType())
|
||||
mModule->mBfIRBuilder->AddPhiIncoming(phi, leftValue.mValue, endLhsBB);
|
||||
if (!rightValue.mType->IsValuelessType())
|
||||
mModule->mBfIRBuilder->AddPhiIncoming(phi, rightValue.mValue, endRhsBB);
|
||||
mResult = BfTypedValue(phi, leftValue.mType);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue