The LEAVE command is a loop modifying command. It causes the current loop to be exited and execution to continue on the statement following the end loop command.
CONTINUE/LEAVE commands work inside all loop commands.
Also See
7.86.2 LEAVE Comments / Warnings
Required
LEAVE -------------------------------------------------------->
-----------------------------------------------------------------
Optional
>-- IF ----------- 'condition' --------------------|