Chapter Contents

Previous

Next
Command Directory

resume

Resume Program Execution

ABBREVIATION
res{ume}

FORMATS

Format 1: resume

Format 2: resume
LINENO
Format 3: resume
FUNCTION-NAME
Format 4: resume
FUNCTION-NAME LINENO

DESCRIPTION
The resume command enables you to resume execution of a program running under the debugger at any line-number hook in any active function in the calling sequence. The resume command, or its alias goto, can be issued when stopped at any line or return hook. While you cannot issue a resume command when stopped at an entry hook, you may be able to step to the first line hook at the opening brace and then issue resume.

You cannot use resume after using the attn command, but you may be able to issue resume after a subsequent break, step, or continue command returns control to you.

The resume command can also be used to attempt recovery from the following types of error conditions:


When you receive one of the signals listed above with a program running under the SAS/C Debugger, you can examine the values of variables, make changes to variables, and so on. Then, issuing resume causes the debugger to discard the signal and resume execution.

The location in your program where execution resumes depends on the format of the resume command that you used and where execution of the program stopped. Note that while you cannot resume a library function or a function compiled with the nodebug option, you can resume a function that called one of these two types of functions. However, the calling function must be compiled with debug .

Because the effect of the resume command is similar to inserting a one-time goto or longjump in the program, when bypassing code, you must ensure that variables contain proper values for resumption of execution at the target hook.

Format 1: This format restarts execution at the last line-number hook encountered before the location stopped.

Format 2: This format resumes execution at the first line-number hook encountered in the source line identified by LINENO in the current function.

Format 3: This format resumes execution at the last line-number hook executed in an active function identified by FUNCTION-NAME.

Format 4: This format resumes execution at the first line-number hook in the specified line (LINENO) of the function named by FUNCTION-NAME. The function must be active.

EXAMPLES

resume
resumes execution at the last line-number hook executed.

resume 23
resumes execution at the first line-number hook encountered in line 23 in the function where it is currently stopped.

resume prevfunc
resumes execution at the last line-number hook executed in the function prevfunc .

resume prevfunc 34
resumes execution at the first line-number hook in line 34 of the function prevfunc .

SYSTEM DEPENDENCIES
none

COMMAND CAN BE ISSUED FROM

PROFILE no
configuration file no
Source window prefix g

SCOPE
The resume command is affected by changes in scope.

RETURN CODES SET
not applicable

SEE ALSO


Chapter Contents

Previous

Next

Top of Page

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