Fixed bug with address miscalculation in ternary operator when compiling with -h or #nocompact flags

This commit is contained in:
Dasperal 2019-10-31 02:57:18 +03:00 committed by Christoph Oelckers
parent 8cb3ad63fe
commit fc4d47b612

View file

@ -3618,8 +3618,8 @@ static void ExprTernary(void)
}
else
{
PC_WriteInt(pc_Address + 5, jumpAddrPtr); // opcode + int = 5 bytes
PC_AppendCmd(PCD_GOTO);
PC_WriteInt(pc_Address + 4, jumpAddrPtr); // int = 4 bytes
jumpAddrPtr = pc_Address;
PC_SkipInt();