Values are used to alter locations, to investigate complex structures in more detail or to filter relevant information out of a large amount of data. There are several (mode dependent) operations defined which enable such investigations. These operations are not only applicable to constant values but also to locations, which can become quite useful when debugging complex structures. During parsing the command line (e.g. evaluating an expression) GDB treats location names as the values behind these locations.
This section describes how values have to be specified and which operations are legal to be used with such values.
Literal Values
Tuple Values
<mode name>[<tuple>]
, where <mode
name>
can be omitted if the mode of the tuple is unambiguous. This
unambiguity is derived from the context of a evaluated expression.
<tuple>
can be one of the following:
String Element Value
<string value>(<index>)
where <index>
is a integer expression. It delivers a character
value which is equivalent to the character indexed by <index>
in
the string.
String Slice Value
<string value>(<slice
spec>)
, where <slice spec>
can be either a range of integer
expressions or specified by <start expr> up <size>
.
<size>
denotes the number of elements which the slice contains.
The delivered value is a string value, which is part of the specified
string.
Array Element Values
<array value>(<expr>)
and
delivers a array element value of the mode of the specified array.
Array Slice Values
<array value>(<slice spec>)
, where
<slice spec>
can be either a range specified by expressions or by
<start expr> up <size>
. <size>
denotes the number of
arrayelements the slice contains. The delivered value is an array value
which is part of the specified array.
Structure Field Values
<structure value>.<field
name>
, where <field name>
indicates the name of a field specified
in the mode definition of the structure. The mode of the delivered value
corresponds to this mode definition in the structure definition.
Procedure Call Value
ULONG
literals.
Values of time mode locations appear as
TIME(<secs>:<nsecs>)
Zero-adic Operator Value
Expression Values
OR, ORIF, XOR
AND, ANDIF
NOT
=, /=
>, >=
<, <=
+, -
*, /, MOD, REM
-
//
()
->
->loc
), or to dereference a reference
location (loc->
).
OR, XOR
AND
NOT
>, >=
<, <=
IN
Go to the first, previous, next, last section, table of contents.