HELP NEWBYTEARRAY                               David Young
                                                November 1994
                                                revised July 2003


LIB * NEWBYTEARRAY provides procedures which make and recognise packed
arrays of bytes. These are suitable for passing to external procedures
that expect such arrays. In addition, a vector class for the
arrayvectors is defined.

newbytearray(bounds_list, element_init) -> byte_array
    The arguments are as for *newarray. The second is optional.

oldbytearray(tag, bounds_list, element_init) -> byte_array
    The last two arguments are as above, with element_init optional.

    The tag argument is an identifier such as a word or integer. If
    oldbytearray is called twice with the same tag, the arrays returned
    may share storage. This can reduce garbage collection, and this
    procedure should be used in preference to newbytearray for any array
    which is only needed temporarily. See *oldarray for more details.

isbytearray(array) -> boolean
    Returns <true> if array is an array with a packed byte arrayvector,
    <false> otherwise. An array for which <true> is returned could have
    been created with, for example, newbytearray, *newsarray,
    *sunrasterfile or some other similar procedure.

A vector class with dataword bytevec is defined. This means that the
constant bytevec_key and the procedures isbytevec, consbytevec,
initbytevec, destbytevec, subscrbytevec and fast_subscrbytevec
are defined and made available. See REF * DEFSTRUCT for an explanation
of what these do, or REF * INTVEC for a description of the equivalent
procedures for a different vector class.


--- $popvision/help/newbytearray
--- Copyright University of Sussex 2003. All rights reserved.
