VMS Help  —  RTL Routines, OTS$  OTS$CVT_TO_L
    The Convert Octal Text to Unsigned Integer routine converts an
    ASCII text string representation of an unsigned octal value to
    an unsigned integer. The integer value can be of arbitrary length
    but is typically a byte, word, longword, or quadword. The default
    size of the result is a longword.

    Format

      OTS$CVT_TO_L  fixed-or-dynamic-input-string

                    ,varying-output-value [,output-value-size]

                    [,flags-value]

1  –  Returns

    OpenVMS usage:cond_value
    type:         longword (unsigned)
    access:       write only
    mechanism:    by value

2  –  Arguments

 fixed-or-dynamic-input-string

    OpenVMS usage:char_string
    type:         character string
    access:       read only
    mechanism:    by descriptor, fixed-length or dynamic string

    Input string containing the string representation of an unsigned
    octal value that OTS$CVT_TO_L converts to an unsigned integer.
    The fixed-or-dynamic-input-string argument is the address of
    a descriptor pointing to the input string. The valid input
    characters are blanks and the digits 0 through 7. No sign is
    permitted.

 varying-output-value

    OpenVMS usage:varying_arg
    type:         unspecified
    access:       write only
    mechanism:    by reference

    Unsigned integer of specified size that OTS$CVT_TO_L creates
    when it converts the ASCII text string. The varying-output-value
    argument is the address of the unsigned integer. The value of the
    output-value-size argument determines the size in bytes of the
    output value.

 output-value-size

    OpenVMS usage:longword_signed
    type:         longword integer (signed)
    access:       read only
    mechanism:    by value

    Arbitrary number of bytes to be occupied by the unsigned integer
    output value. The output-value-size argument contains a value
    that equals the size in bytes of the output value. If the value
    of output-value-size is zero or a negative number, OTS$CVT_TO_L
    returns an input conversion error. If you omit the output-value-
    size argument, the default is 4 (longword).

 flags-value

    OpenVMS usage:mask_longword
    type:         longword (unsigned)
    access:       read only
    mechanism:    by value

    User-supplied flag that OTS$CVT_TO_L uses to determine how
    to interpret blanks within the input string. The flags-value
    argument contains the user-supplied flag described in the
    following table:

    Bit  Action if Set    Action if Clear

    0    Ignore all       Interpret blanks as zeros.
         blanks.

    If you omit the flags-value argument, OTS$CVT_TO_L defaults the
    flag to clear.
Close Help