Marc's Place

DIBIOL/DBL - Argument/Field Definitions

Subroutine argument definitions specify the data linkages between
an external subroutine and the program that called the external subroutine.

             |{GROUP}    |{name},{{*{,*...}}}t |{.}   |
             |{qualifier}|                     |{size}|


       These further describe the argument being passed. Valid qualifiers are:

               %VAL          Argument was passed by value.
               %REF          Argument was passed by reference (size is required
                             when %REF is specified).
               %DESCR        Argument was passed by descriptor. This is the default.

Field definitions define variables within a RECORD or COMMON area.

                                            |n  |
                                            |*  |

Array-information: An array is a group of fields which share the same data type, field
size, and symbolic name (array name).

     For pseudo-arrays:

             {name}, d1 t n {values}

     For single or multi-dimensional arrays:

             {name},[d1{,d2...dn}] t n {values}

    Valid types are A (alpha), D (zoned), P (packed), I (integer)
    n, n.p, *: type = A, max 65535 bytes; = D, max 18; = P, max 18; = I, max 16 bytes.
               p = number of decimal places whithin field, i.e.: D5.2 >> XXX,XX
               * = size will be generated by the compiler.

        MSG, A, "Dit zijn twintig pos"       ; Creates an A20 field

        PSEUDO, 2A*, "ABCD", "EFGHIJ"        ; Creates a 2A6 field

        ZONED, D, 123.45                     ; Creates a D5.2 field

        INTGER, I*, 42                       ; Creates an I1 field.

Field definitions define literals within a LITERAL area.


GLOBAL (in main) and EXTERNAL (in routine/function) may be used only with the integer
data type (for example a channel number).

        chklt,        I, 10
        arrayelem,    I, 20     ; 20 elements
        arraysize,    I, 10     ; 10 digits/bytes

        array,        arrayelem A arraysize
© 1997- Marc Vos (and others)   -   Privacy Statement   -    Contact Me