pTAL Conversion Guide

Equivalenced Variables
pTAL Conversion Guide527302-002
12-7
Declaring Equivalenced Structures
field-alignment
specifies the memory alignment for the base of the structure and for fields within
the structure. See Section 11, Structures, for details about the FIELDALIGN
clause.
previous-identifier
is the name of a previously declared simple variable, direct array element,
structure, structure layout, structure pointer, or equivalenced variable.
index
is an INT constant that specifies the offset of the element in previous-
identifier to which the equivalenced pointer or variable refers. Specify index
only with direct variables. index must end on a word boundary.
offset
is an INT constant that specifies a word offset. Specify offset only with direct or
indirect variables. For indirect variables, the offset is from the location of the
pointer, not from the location of the data pointed to.
structure-layout
is a BEGIN-END construct that contains declarations. See the TAL Reference
Manual and TAL Programmer’s Guide for further information about TAL
declarations.
You must specify either referral or structure-layout but not both in an equivalenced
structure declaration.
You can specify a FIELDALIGN clause only if you specify structure-layout. You cannot
specify a FIELDALIGN clause for a referral structure.
Example 12-3. Equivalenced Structure Declarations (page 1 of 2)
STRUCT a;
BEGIN
INT i;
INT j;
END;
FIELDALIGN
( SHARED2
SHARED8
AUTO
PLATFORM
)
VST992.vsd