protected override void VisitBranchOnTrueInstruction(BranchOnTrueInstruction instruction) { ControlState.EvaluationStack.Pop(out var stackVal); var branch = ComputeUnaryBranchOperation( stackVal, a => a.Value != 0, a => a.Value != 0 ); if (branch) { ControlState.Move(instruction.Offset, instruction.Label); } else { ControlState.MoveToNextInstruction(); } }
protected abstract void VisitBranchOnTrueInstruction(BranchOnTrueInstruction instruction);