Fix OptStackOps label migration case for toscmpbool, add test case
This commit is contained in:
@@ -1153,6 +1153,8 @@ static unsigned Opt_a_toscmpbool (StackOpData* D, const char* BoolTransformer)
|
||||
|
||||
/* Save lhs into zeropage */
|
||||
AddStoreLhsA (D);
|
||||
/* AddStoreLhsA may have moved the OpIndex, recalculate insertion point to prevent label migration. */
|
||||
D->IP = D->OpIndex + 1;
|
||||
|
||||
/* cmp */
|
||||
X = NewCodeEntry (OP65_CMP, AM65_ZP, D->ZPLo, 0, D->OpEntry->LI);
|
||||
|
||||
Reference in New Issue
Block a user