mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 04:22:20 +02:00
Zero-sized array count lookup fix
This commit is contained in:
parent
27a586df04
commit
8c391fe4f5
1 changed files with 4 additions and 1 deletions
|
@ -8749,7 +8749,10 @@ void BfExprEvaluator::LookupQualifiedName(BfAstNode* nameNode, BfIdentifierNode*
|
|||
if (mResult.mType->IsSizedArray())
|
||||
{
|
||||
mResult.mType = mModule->GetWrappedStructType(mResult.mType);
|
||||
mResult.mValue = mModule->mBfIRBuilder->CreateBitCast(mResult.mValue, mModule->mBfIRBuilder->MapTypeInstPtr(mResult.mType->ToTypeInstance()));
|
||||
if (mResult.mType->IsValuelessType())
|
||||
mResult.mValue = mModule->mBfIRBuilder->GetFakeVal();
|
||||
else
|
||||
mResult.mValue = mModule->mBfIRBuilder->CreateBitCast(mResult.mValue, mModule->mBfIRBuilder->MapTypeInstPtr(mResult.mType->ToTypeInstance()));
|
||||
}
|
||||
else if (mResult.mType->IsWrappableType())
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue