[net.lang.mod2] SET types

CSvax:Pucc-H:Physics:hal@pur-ee.UUCP (10/14/83)

    What size limitations does your Modula-2 compiler put on SET types?
Do you use the standard type BITSET when programming high-level (i.e.
"machine-independent") modules or do you usually define SETs on some
enumeration type?  Is "SET OF CHAR" acceptable to your compiler?
I'm curious.

Hal Chambers
Purdue

adrian@ru-cs44.UUCP (10/18/83)

Again, the Univ. NSW M2 compiler for UNIX v7, derived from ETH RT-11
compiler:

Our compiler enforces a limit of 16 things per set.  See the section
6.6 in the report:

"A set type defined as SET OF T comprises all sets of values of its
base type T.  This must be a subrange of the integers between 0 and
WordSize-1 (in our case 15), or a (subrange of an) enumeration type
with at most WordSize values."

That seems pretty clear to me, the report limits sets to WordSize
elements, and, thus, SET OF CHAR is not allowed.

That is not to say that I agree with the restriction.  It's one of
the features of M2 that I'll get round to changing one day.  As I
recall, our first PASCAL compiler had a similar restriction ...
-- 
Adrian Pell		({vax135,mcvax,edcaad}!ukc!ru-cs44!adrian)
Computer Science Dept.
University of Reading
UK