Search                        Top                                  Index
HELP CHAINTO                            Ros Barrett, January 1986

    chainto(<procedure 1 | call stack length>, <procedure 2>)

CHAINTO takes two arguments:

  1. a target procedure to chain to, or a call stack length (e.g.
        the result of *CALLSTACKLENGTH) implicitly identifying a
        target procedure. (procedure 1)
  2. a procedure to run. (procedure 2)

As with *CHAINFROM, the target may be either an actual procedure, or a
call stack length as returned by *CALLSTACKLENGTH. The procedure
provided as the second argument is then simply run. When (or if) it
finishes, control will return to the target procedure. Unlike
*CHAINFROM, a *CHAIN does not actually take place. Control unwinds from
the caller to the target which is provided as the first argument.

-- RELATED DOCUMENTATION ----------------------------------------------

See also:

Other non-standard control structures:
HELP *CALLER    - identifies a single caller at a specified level
HELP *INTERRUPT - On POP-11 interrupt procedures
HELP *CONTROL   - For a summary of control structures in POP-11
REF  *PROCEDURE   - details of the nature of procedures in POP-11

--- C.all/help/chainto -------------------------------------------------
--- Copyright University of Sussex 1987. All rights reserved. ----------