Chapter Contents

Previous

Next
Command Directory

where

Produce a Traceback

ABBREVIATION
w{here}

FORMATS
Format 1: where
Format 2: where full

DESCRIPTION
Format 1: Format 1 produces a traceback showing functions active at the point in a program where the where command is issued. You can use the where command to determine the sequence of functions that are active or whether you are executing in the appropriate section. If command scope is different from run scope, the command scope is marked by an asterisk in the traceback produced by the where command.

Because source lines and variables are accessed only for active functions, another use of where is to display a list of active functions to determine what variables can be accessed. (An external variable, of course, can be accessed from any function whose context contains a declaration for it.)

Format 2: Format 2 causes the debugger to print address and offset information in the traceback as well.

EXAMPLES
The following examples show tracebacks that were produced during a line-mode session. If you are using extended names, your traceback will look different. See auto for more information about extended names.
   CDEBUG:
   where
   Calling trace:
       Function        Line    Context
     READIN(MAIN)        50
       MAIN(MAIN)        29*


   CDEBUG:
   where full
   Calling trace:
       Function        Line    Offset     Address    Context
     READIN(MAIN)        50    00007E    000470F2
       MAIN(MAIN)        29*   000086    0004700E

SYSTEM DEPENDENCIES
none

COMMAND CAN BE ISSUED FROM

PROFILE no
configuration file no
Source window prefix none

SCOPE
The where command is not affected by changes in scope.

RETURN CODES SET
Successful: 0
Unsuccessful: 1

SEE ALSO
scope


Chapter Contents

Previous

Next

Top of Page

Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.