Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ env.v — Apollo

Media Vault

Software Library

Restoration Projects

Artifacts Sought

ENVIRONMENT -- Changes or identifies an environment.


FORMAT

                statement-id
                -Run
  Environment   -User
                -Caller
                -Sub


REQUIRED ARGUMENTS

  None.            If you do not supply an argument, the command returns the
                   name of the current environment.


OPTIONAL ARGUMENTS

  statement-id     Sets the user environment to the given location.  Usually,
                   you just specify a routine-name, sometimes you specify a
                   particular statement-number within the routine.  When
                   dealing with recursive routines, you may also want to
                   specify an activation-number.

  -Run             Sets the current environment to the run environment.

  -User            Sets the current environment to the user environment.

  -Caller          Sets the user environment to the statement that called the
                   current routine.  The current routine must be active.  This
                   option and -SUB provide a convenient way to "walk" up and
                   down the call stack.

  -Sub             Sets the user environment to the routine called by the
                   current routine.  The current routine must be active.  This
                   option is essentially the opposite of -Caller.


DESCRIPTION

  Use the ENVIRONMENT command to set or describe an environment. The
  "environment" is the default routine that DEBUG searches when you do not
  explicitly specify a routine.  DEBUG recognizes three different kinds of
  environments:

    user environment -- the routine you name with the ENVIRONMENT command.

    run environment -- the routine at which the program is stopped.

    current environment -- whichever of the two previous environments that
                           DEBUG is currently using in its calculations.

  Many debugger operations implicitly reference the current environment.
  For example, if you ask to examine variable X, and don't qualify X
  with a particular routine name, the debugger will show you the X visible
  from the current environment.  If X is not visible from the current
  environment, for instance, if it is defined in another routine, then
  DEBUG will not be able to find it.

  Environment really only becomes important when you the program is stopped
  in one module, but you want to access information stored in a different
  module.

  For full details, see Chapter 3 of the DOMAIN Language Level Debugger
  Reference manual.

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026