Fix == instead of = for assignment

This commit is contained in:
drmortalwombat 2022-03-11 13:07:38 +01:00
parent 6f52a7beed
commit 3cb4bd0fba
2 changed files with 4 additions and 4 deletions

View File

@ -2632,8 +2632,8 @@ bool InterInstruction::ConstantFolding(void)
mCode = IC_CONSTANT; mCode = IC_CONSTANT;
mConst.mIntConst = ::ConstantFolding(mOperator, mSrc[0].mType, 0, 0); mConst.mIntConst = ::ConstantFolding(mOperator, mSrc[0].mType, 0, 0);
mConst.mType = IT_BOOL; mConst.mType = IT_BOOL;
mSrc[0].mTemp == -1; mSrc[0].mTemp = -1;
mSrc[1].mTemp == -1; mSrc[1].mTemp = -1;
mNumOperands = 0; mNumOperands = 0;
return true; return true;
} }

View File

@ -17373,8 +17373,8 @@ bool NativeCodeBasicBlock::PeepHoleOptimizer(NativeCodeProcedure* proc, int pass
mIns[i + 4].mType == ASMIT_STA && !mIns[i + 2].SameEffectiveAddress(mIns[i + 4]) && !(mIns[i + 4].mLive & (LIVE_CPU_REG_A | LIVE_CPU_REG_Z | LIVE_CPU_REG_X))) mIns[i + 4].mType == ASMIT_STA && !mIns[i + 2].SameEffectiveAddress(mIns[i + 4]) && !(mIns[i + 4].mLive & (LIVE_CPU_REG_A | LIVE_CPU_REG_Z | LIVE_CPU_REG_X)))
{ {
mIns[i + 0] = mIns[i + 4]; mIns[i + 0] = mIns[i + 4];
mIns[i + 3].mType = ASMIT_NOP; mIns[i + 3].mMode == ASMIM_IMPLIED; mIns[i + 3].mType = ASMIT_NOP; mIns[i + 3].mMode = ASMIM_IMPLIED;
mIns[i + 4].mType = ASMIT_NOP; mIns[i + 4].mMode == ASMIM_IMPLIED; mIns[i + 4].mType = ASMIT_NOP; mIns[i + 4].mMode = ASMIM_IMPLIED;
progress = true; progress = true;
} }
} }