Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

QUIT

1984 Version of ANSI Standard

3.6.13 QUIT

Q[UIT] postcond [ Space ]

The end-of-routine mark eor is equivalent to an unconditional QUIT. If the last command of the routine is executed in such a manner as not to transfer control, or if the last command of the routine is an executed DO and control is returned, then the effect of executing off the end of the routine is to execute the QUIT which is implied by the eor.

The effect of executing QUIT in the scope of FOR is fully discussed in 3.6.5

Note the eor never occurs in the scope of FOR.

If an executed QUIT is not in the scope of FOR, then it is in the scope of some doargument or xargument, if not explicitly then implicitly, because the initial activation of a process may be thought of as arising from execution of a DO naming the first executed routine of that process. The effect of executing a QUIT in the scope of a doargument or xargument is to return control to the most recently executed doargument or xargument to which control has not yet been returned by a QUIT. What is executed immediately following the QUIT is the command, doargument, or xargument immediately following the doargument or xargument which most recently transferred control and to which control has not yet been returned. Thus, executed doarguments and xarguments are added to a list of pending returns from which execution of a QUIT (not in the scope of FOR) removes entries in last-in, first-out order.

See also the transition diagram for Quit.

Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Copyright © Standard Documents; 1977-2024 MUMPS Development Committee;
Copyright © Examples: 1995-2024 Ed de Moel;
Copyright © Annotations: 2003-2008 Jacquard Systems Research
Copyright © Annotations: 2008-2024 Ed de Moel.

This page most recently updated on 15-Nov-2023, 14:46:53.

For comments, contact Ed de Moel (demoel@jacquardsystems.com)