# Type Declarations within Record Structures

The syntax of a type declaration within a record structure is identical to that of a normal Fortran type statement.

The following rules and behavior apply to type declarations in record structures:

- %FILL can be specified in place of a field name to leave space in a record for purposes such as alignment. This creates an unnamed field.

  %FILL can have an array specification; for example:

        INTEGER %FILL (2,2)

  Unnamed fields cannot be initialized. For example, the following statement is invalid and generates an error message:

        INTEGER %FILL /1980/

- Initial values can be supplied in field declaration statements. Unnamed fields cannot be initialized; they are always undefined.

- Field names must always be given explicit data types. The IMPLICIT statement does not affect field declarations.

- Any required array dimensions must be specified in the field declaration statements. DIMENSION statements cannot be used to define field names.

- Adjustable or assumed sized arrays and assumed-length CHARACTER declarations are not allowed in field declarations.

Parent topic: Structure Declarations