1 03/05/85 decode_descriptor_
2
3
4 The decode_descriptor_ subroutine extracts information from argument
5 descriptors. It should be called by any procedure wishing to handle
6 variable length or variable type argument lists. It processes the
7 descriptor format used by PL/I, BASIC, COBOL, FORTRAN, and Pascal.
8
9
10 Entry points in decode_descriptor_:
11 List is generated by the help command
12
13
14 :Entry: decode_descriptor_: 03/05/85 decode_descriptor_
15
16
17 Function:
18 extracts information from argument descriptors.
19
20
21 Syntax:
22 declare decode_descriptor_ entry ptr fixed bin fixed bin
23 bit1 aligned fixed bin fixed bin24 fixed bin;
24 call decode_descriptor_ ptr n type packed ndims size scale;
25
26
27 Arguments:
28 ptr
29 points either directly at the descriptor to be decoded or at the
30 argument list in which the descriptor appears. Input
31 n
32 controls which descriptor is decoded. If n is 0, ptr points at the
33 descriptor to be decoded; otherwise, ptr points at the argument list
34 header and the nth descriptor is decoded. Input
35 type
36 is the data type specified by the descriptor. Output
37 -1 is returned if descriptors are not present in the argument list,
38 if the nth descriptor does not exist, or if the descriptor is in
39 an old format
40
41
42 packed
43 describes how the data is stored. Output
44 "1"b data is packed
45 "0"b data is not packed
46 ndims
47 indicates the number of dimensions of an array. Output
48
49 N descriptor is an array of N dimensions
50 0 descriptor is a scalar
51 size
52 is the arithmetic precision, string size, or number of structure
53 elements. Output
54 scale
55 is the scale of an arithmetic value. Output