+-------------------------------IBM Extension--------------------------------+
Purpose
The RECORD statement is a special form of type declaration statement. Unlike other type declaration statements, attributes for entities declared on the RECORD statement cannot be specified on the statement itself.
Format
Record entity declarations follow this syntax:
record_stmt:
.-,------------------------------------------. V | >>-RECORD----/ type_name /--+----+--record_obj_dcl_list-+------>< '-::-'
record_obj_dcl:
>>-record_object_name--+----------------+---------------------->< '-(-array_spec-)-'
where type_name must be the name of a derived type that is accessible in the scoping unit.
Rules
Entities cannot be initialized in a RECORD statement.
A record_stmt declares an entity to be of the derived type, specified by the type_name that most immediately precedes it.
The RECORD keyword cannnot appear as the type_spec of an IMPLICIT or FUNCTION statement.
Examples
In the following example, a RECORD statement is used to declare a derived type variable.
STRUCTURE /S/ INTEGER I END STRUCTURE STRUCTURE /DT/ INTEGER I END STRUCTURE RECORD/DT/REC1,REC2,/S/REC3,REC4
Related Information
+----------------------------End of IBM Extension----------------------------+