mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 19:48:20 +02:00
Fixed erroneous tempaddr takeover in var decl
This commit is contained in:
parent
eccd691079
commit
cbacf99a61
1 changed files with 1 additions and 1 deletions
|
@ -1546,7 +1546,7 @@ BfLocalVariable* BfModule::HandleVariableDeclaration(BfVariableDeclaration* varD
|
||||||
unresolvedType = initValue.mType;
|
unresolvedType = initValue.mType;
|
||||||
resolvedType = unresolvedType;
|
resolvedType = unresolvedType;
|
||||||
|
|
||||||
if (initValue.IsTempAddr())
|
if ((initValue.IsTempAddr()) && (!localDef->mAddr) && (initValue.mType == resolvedType))
|
||||||
{
|
{
|
||||||
// Take over value
|
// Take over value
|
||||||
localDef->mAddr = initValue.mValue;
|
localDef->mAddr = initValue.mValue;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue