I know there exists the LEAVE statement for data step DO loops to terminate the current loop. I cannot find, however, documentation for a corresponding macro command.
I've tried %LEAVE
but that appears not to be defined.
%GOTO
or a DATA _NULL_
?No, unfortunately there is no equivalent of leave
in the macro language (as of v9.4).
You can see a complete list of macro statements in the documentation in the Macro Language Dictionary.
As a workaround you will have to manually trigger an exit condition for your loop.