mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 04:22:20 +02:00
Fixed some var usage
This commit is contained in:
parent
54fa1e0811
commit
e1656865bb
3 changed files with 24 additions and 37 deletions
|
@ -1385,8 +1385,7 @@ BfLocalVariable* BfModule::HandleVariableDeclaration(BfVariableDeclaration* varD
|
|||
}
|
||||
if (!initValue)
|
||||
{
|
||||
initValue = GetDefaultTypedValue(GetPrimitiveType(BfTypeCode_Var));
|
||||
SetHadVarUsage();
|
||||
initValue = GetDefaultTypedValue(GetPrimitiveType(BfTypeCode_Var));
|
||||
}
|
||||
if (initValue.mType->IsNull())
|
||||
{
|
||||
|
@ -5455,8 +5454,7 @@ void BfModule::Visit(BfForEachStatement* forEachStmt)
|
|||
}
|
||||
else if (isVarEnumerator)
|
||||
{
|
||||
// Generic method or mixin decl
|
||||
BF_ASSERT(mBfIRBuilder->mIgnoreWrites || mHadVarUsage);
|
||||
// Generic method or mixin decl
|
||||
}
|
||||
else if (!target.mType->IsTypeInstance())
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue