A typical SET statement may have the form

SET(CHARACTER) M,KK

and identifies M and KK as sets which contain values of the type CHARACTER.

The GROUP statement has the same syntax as the SET statement, and declares entities that can be used interchangeably with SETs in expressions. The difference is that the internal representation of a SET is to be optimized around rapid performance of union and intersection type operations, and that of a GROUP is to emphasize speed in obtaining a list of the elements of the GROUP. Thus, SET might be implemented as a modified bitmap, and GROUP as a modified ordered list; modifications being needed to allow SET(INTEGER) and GROUP(REAL). Having two such types is as reasonable as having both INTEGER and PACKED variables. Where SET(REAL) is specified, GROUP(REAL) can be used to implement it even though SET and GROUP differ for other types (bitmap being useless for so densely packed a type as REAL).

Incidentally, implementors need not provide mechanisms to represent sets as small programs; FALCON does not provide any means of assigning a set whose boundary is fractal to a set variable: the finite approximation of such a set resulting from the limited grain size of machine arithmetic would have to be spelled out explicitly to be assigned in the first place.

[Next] [Up] [Previous]