Data Definition Language (DDL) Reference Manual (G06.24+)

Definition Attributes
Data Definition Language (DDL) Reference Manual426798-002
6-91
89 Enumeration Clause
For COBOL85, the level 89 enumeration clauses for a field of type ENUM are
translated into level 88 items. These items follow the source code for the ENUM
field, a NATIVE-2 clause.
For FORTRAN, the level 89 enumeration clauses for a field of type ENUM are
translated into comments. These comments follow the source code for the ENUM
field, an INTEGER*2 type declaration.
For Pascal, the level 89 enumeration clauses for a field of type ENUM are
translated into constants. These constants precede the type declaration for the
definition or record within the same section.
For pTAL or TAL, the level 89 enumeration clauses for a field of type ENUM are
translated into LITERALs. If the type of a single-field definition is ENUM, and you
do not specify NOTALALLOCATE, DDL generates LITERALs followed by an INT
for the definition; for example:
LITERAL ENUMERATION-NAME1 = ENUMERATION-VALUE1,
ENUMERATION-NAME2 = ENUMERATION-VALUE2,
... ;
INT DEF-NAME;
If the type of a field in a group definition is ENUM, DDL generates LITERALs
followed by a STRUCT template.
For TACL, the level 89 enumeration clauses for a field of type ENUM are translated
into ?SECTION directives of type TEXT followed by an ENUM for the item with
which the level 89 clauses are associated:
?Section ENUMERATION-NAME1 Text
ENUMERATION-VALUE1
?Section ENUMERATION-NAME2 Text
ENUMERATION-VALUE2
...
?Section DEF-NAME Struct
Begin
ENUM DEF-NAME;
End;
Enumeration Clause Examples
The following examples show DDL enumeration clauses and the source code that DDL
generates for these clauses in different languages.