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

Fixed mouseover for 'var' in foreach over structs

This commit is contained in:
Brian Fiete 2024-10-13 10:22:54 -04:00
parent 01eb80c3d4
commit 0e6ad7304e

View file

@ -6775,6 +6775,8 @@ void BfModule::Visit(BfForEachStatement* forEachStmt)
BfTypedValue varTypedVal;
bool needsValCopy = true;
BfType* origVarType = varType;
// Local variable
{
if (!tupleBinds.IsEmpty())
@ -6914,7 +6916,7 @@ void BfModule::Visit(BfForEachStatement* forEachStmt)
innerScopeData.mIsLoop = true;
if ((autoComplete != NULL) && (forEachStmt->mVariableTypeRef != NULL))
autoComplete->CheckVarResolution(forEachStmt->mVariableTypeRef, varType);
autoComplete->CheckVarResolution(forEachStmt->mVariableTypeRef, origVarType);
if (isArray || isSizedArray)
mBfIRBuilder->CreateAlignedStore(GetConstValue(0), itr.mValue, itr.mType->mAlign);