Compaq COBOL AAQ2G1FTK User Manual
Page 471

Using Compaq COBOL in the Alpha Common Language Environment
13.4 Calling Routines
Table 13–4 (Cont.) COBOL Implementation of the OpenVMS Alpha Data Types (OpenVMS)
OpenVMS Alpha Data
Type
COBOL Definition
ast_procedure
01 AST-PROC PIC 9(9) COMP.
2
boolean
01 BOOLEAN-VALUE PIC 9(9) COMP.
2
byte_signed
NA . . . PIC X.
1
byte_unsigned
NA . . . PIC X.
1
channel
01 CHANNEL PIC 9(4) COMP.
2
char_string
01 CHAR-STRING PIC X to PIC X(65535).
complex_number
NA . . . PIC X(n) where n is length.
1
cond_value
01 COND-VALUE PIC 9(9) COMP.
2
context
01 CONTEXT PIC 9(9) COMP.
2
date_time
NA . . . PIC X(8).
1
device_name
01 DEVICE-NAME PIC X(n) where n is length.
d_floating
01 D-FLOAT USAGE COMP-2.
(when /FLOAT=D_FLOAT)
ef_cluster_name
01 CLUSTER-NAME PIC X(n) where n is length.
ef_number
01 EF-NO PIC 9(9) COMP.
2
exit_handler_block
NA . . . PIC X(n) where n is length.
1
fab
NA . . . Too complex for general COBOL use. Most of a FAB structure can be
described by a lengthy COBOL record description, but such a FAB cannot then
be referenced by a COBOL I-O statement. It is much simpler to do the
I-O completely within COBOL, and let the COBOL compiler generate the FAB
structure, or do the I-O in another language.
file_protection
01 FILE-PROT PIC 9(4) COMP.
2
function_code
01 FUNCTION-CODE.
02 MAJOR-FUNCTION PIC 9(4) COMP.
2
02 SUB-FUNCTION PIC 9(4) COMP.
2
f_floating
01 F-FLOAT USAGE COMP-1.
(when /FLOAT=D_FLOAT or /FLOAT=G_FLOAT)
g_floating
01 G-FLOAT USAGE COMP-2.
(when /FLOAT=G_FLOAT)
identifier
01 ID PIC 9(9) COMP.
2
io_status_block
01 IOSB.
02 COND-VAL PIC 9(4) COMP.
2
02 BYTE-CNT PIC 9(4) COMP.
2
02 DEV-INFO PIC 9(9) COMP.
2
item_list_2
01 ITEM-LIST-TWO.
02 ITEM-LIST OCCURS n TIMES.
04 COMP-LENGTH PIC S9(4) COMP.
04 ITEM-CODE PIC S9(4) COMP.
04 COMP-ADDRESS PIC S9(9) COMP.
02 TERMINATOR PIC S9(9) COMP VALUE 0.
1
Most OpenVMS Alpha data types not directly supported in COBOL can be represented as an alphanumeric data item
of a certain number of bytes. While COBOL does not interpret the data type, it may be used to pass objects from one
language to another.
2
Although unsigned computational data structures are not directly supported in COBOL, you may substitute the signed
equivalent provided you do not exceed the range of the signed data structure.
(continued on next page)
Using Compaq COBOL in the Alpha Common Language Environment 13–9