The Chill Datatype- (Mode) support of GDB is directly related with the functionality of the GNU Chill compiler, and therefore deviates slightly from the standard specification of the Chill language. The provided modes are:
Discrete modes:
BYTE, UBYTE, INT,
UINT, LONG, ULONG
,
BOOL
,
CHAR
,
SET
.
(gdb) ptype x type = SET (karli = 10, susi = 20, fritzi = 100)If the type is an unnumbered set the set element values are omitted.
type = <basemode>(<lower bound> : <upper bound>)
where <lower bound>, <upper bound>
can be of any discrete literal
expression (e.g. set element names).
Powerset Mode:
POWERSET
followed by
the member mode of the powerset. The member mode can be any discrete mode.
(gdb) ptype x type = POWERSET SET (egon, hugo, otto)
Reference Modes:
REF
followed by the mode name to which the reference is bound.
PTR
.
Procedure mode
type = PROC(<parameter list>)
<return mode> EXCEPTIONS (<exception list>)
. The <parameter
list>
is a list of the parameter modes. <return mode>
indicates
the mode of the result of the procedure if any. The exceptionlist lists
all possible exceptions which can be raised by the procedure.
Synchronization Modes:
EVENT (<event length>)
where (<event length>)
is optional.
BUFFER (<buffer length>)<buffer element mode>
where (<buffer length>)
is optional.
Timing Modes:
DURATION
TIME
Real Modes:
REAL
and LONG_REAL
.
String Modes:
CHARS(<string length>)
followed by the keyword VARYING
if the String Mode is a varying
mode
BOOLS(<string
length>)
Array Mode:
ARRAY(<range>)
followed by the element mode (which may in turn be an array mode).
(gdb) ptype x type = ARRAY (1:42) ARRAY (1:20) SET (karli = 10, susi = 20, fritzi = 100)
Structure Mode
STRUCT(<field
list>)
. The <field list>
consists of names and modes of fields
of the structure. Variant structures have the keyword CASE <field>
OF <variant fields> ESAC
in their field list. Since the current version
of the GNU Chill compiler doesn't implement tag processing (no runtime
checks of variant fields, and therefore no debugging info), the output
always displays all variant fields.
(gdb) ptype str type = STRUCT ( as x, bs x, CASE bs OF (karli): cs a (ott): ds x ESAC )
Go to the first, previous, next, last section, table of contents.