In this example, a TESTCB macro is used to test whether ENDPROC
is the routine supplied for the EODAD exit in the exit list EXITS,
and whether the EODAD exit is active. A branch table is used to determine
whether the test is successful.
TESTCB EODAD=(ENDPROC,A), Is ENDPROC supplied and is the exit x
EXLST=EXITS active?
B *+4(15)
If the test was made successfully, register
15 contains 0 and the next instruction is executed.
B TEST1
If it was unsuccessful,
register 15 contains 4 and the next instruction is executed.
ABEND 2,DUMP
TEST1 BNE NO
YES ... Yes; ENDPROC is supplied and active.
NO ... ENDPROC is not supplied, or the exit
is not active.