This allows a calling program unit to specify labels as arguments to a called procedure as shown. The called procedure can then return control to different points in the calling program unit by specifying an integer parameter to the RETURN statement which corresponds to a set of labels specified in the argument list.
... CALL SUB1(x,y,*98,*99) ... 98 CONTINUE ... 99 CONTINUE ... SUBROUTINE SUB1(X,Y,*,*) ... RETURN 1 ... RETURN 2 END
Use an INTEGER return code and a GOTO statement or some equivalent control structure.