ST Statement: JMP
The JMP
statement is used for executing an unconditional jump to a program line that is marked by a jump label.
Syntax:
<label>: <instructions> JMP <label>;
The jump label <label>
is any unique identifier that you place at the beginning of a program line. On reaching the JMP
statement, a return to the program line with the <label>
takes place.
Example 76. Example
iVar1 := 0; _label1: iVar1 := iVar1+1; (*instructions*) IF (iVar1 < 10) THEN JMP _label1; END_IF;
Important
You must use programming to make sure that no infinite loops are caused. For example, you can make the jump conditional.