Chapter Contents |
Previous |
Next |
Command Directory |
Transfer Debugger/Program Values to CLIST/EXEC Variables
tran{sfer}
transfer
command enables you to assign different character strings containing debugger
information or program values to CLIST/EXEC variables. The transfer
command facilitates communication between the debugger
and CLISTs and EXECs. Note that transfer
is
issued to the debugger by a CLIST or EXEC, not from the Command window.
In all the formats above, VAR-NAME is any valid CLIST
or EXEC variable name. VAR-NAME is limited to 64 characters. FMT-SPEC is a
valid format, which means any valid
printf
specification, provided
it begins with a %.
Individual settings are transferred by specifying the keyword.
-N
option) in the calling sequence. This version of
Format 2 is
transfer VAR-NAME [FMT-SPEC] address [-N] |
The formatted string contains the appropriate offset
in hexadecimal format with a leading
0p
, for example,
0p00123456
. At the return line-number hook, on the jumper's side of
the
longjmp
function, an address is not available, and
n/a is returned.
transfer VAR-NAME sname [-N] |
transfer VAR-NAME fname [-N] |
This is similar to using sname. However, the string may contain leading blanks.
transfer VAR-NAME [FMT-SPEC] lineno [-N] |
transfer VAR-NAME [FMT-SPEC]offset [-N] |
The
formatted string contains the specified offset in
hex with a leading
0p
, for example,
0p0002BE
. At the return hook, an offset is not available, and n/a is returned.
If an FMT-SPEC is given, the string assigned to VAR-NAME
is similar to that created for the print
command,
but without the expression : prefix. Strings can be transferred by specifying
%s
printf
format specification, but using the str keyword may be more
natural. (See Format 4, which is described next.)
If no FMT-SPEC is given, the default output is as follows:
short
and
long
|
the decimal value using the %d format for signed and %u for unsigned. |
char
|
printable: x form escape character: \ n form otherwise: \ xnn |
float
|
and
double
%.6E and %.15E,
respectively. |
0p
.
enum
. The
enum
constant is printed. If there is no
enum
constant corresponding
to the value, the value in decimal is printed.
Format 4: EXPRESSION is any valid expression
accepted by the dump
command, which is any
address type expression. If the optional, N is not specified, a null-terminated
string is copied to VAR-NAME. Otherwise, N bytes, followed by a null byte,
are copied. The following examples illustrate this format. Assume
a=abcdef
.
transfer xyz str a (xyz gets the string "abcdef ") |
transfer xyz str a,3 (xyz gets the string "abc") |
Format 5: EXPRESSION is any valid expression
accepted by the dump
command, which is any
address type expression. If the optional, N is not specified, the hex representation
of a null-terminated string is copied to VAR-NAME. Otherwise, the hex representation
of N bytes is copied. Again assuming
a=abcdef"
, the following
examples illustrate this format:
transfer xyz dump a (xyz gets the string & "818283848586") |
transfer xyz dump a,3 (xyz gets the string "818283") |
Format
6: Format 6 assigns the type of
an expression to a CLIST/EXEC variable. The string assigned to VAR-NAME is
a string that describes the expression in C terms. Assume
i
,
cp
, and
sp
are declared as follows:
int i; char * cp; struct SSS * sp;
Then, this format is illustrated as follows:
transfer xyz typeof i(xyz gets the string "int") |
transfer xyz typeof cp(xyz gets the string "char *") |
transfer xyz typeof sp (xyz gets the string "struct SSS *")} |
NNNN REASON FNAME (SNAME) LINE-SPEC | |
NNNN monitor MON-DET | |
0000 signal SIGNAL-NAME | |
0000 attn |
MON-DET is what appears for that monitor if you do a query
.
TERMIN | |
TERMOUT | |
SIGNAL | |
ATTN | |
MONITOR | |
BREAK
(also generated for on
commands) | |
RUNTO | |
CONT | |
STEP |
transfer
commands that demonstrate how you can transfer debugger
variable values to CLIST or EXEC variables.
transfer
command uses command scope to resolve references
to all identifiers.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.