phipps@fortune.UUCP (Clay Phipps) (07/12/84)
[Beware the jabberwock !]
These results show the inconsistency in type checking enums - some
bizzare operations are allowed without any warning (like enum * enum)
and some reasonable operations are not allowed (like array indexing).
Has a standard been developed for what operations should and should not
be allowed on enums?
Sure it has: ANSI/IEEE 770X3.97-1983: "Programming Language Pascal". :-)
Quick ! Get me that asbestos suit !
Don't know why it was (as Ritchie The Revered reportedly said) "a botch"
in C, except that it was such a late addition to the language,
and may have violated some fundamental simplifying assumptions
about how things were done.
-- Clay Phipps
soon to be flamed to a crisp at ...
--
{ amd hplabs!hpda sri-unix ucbvax!amd }
!fortune!phipps
{ ihnp4 cbosgd decvax!decwrl!amd harpo allegra}henry@utzoo.UUCP (Henry Spencer) (07/13/84)
> Don't know why it was (as Ritchie The Revered reportedly said) "a botch" > in C, except that it was such a late addition to the language, > and may have violated some fundamental simplifying assumptions > about how things were done. Dennis talked about this a bit at the Usenix session. What he said was roughly like this: "I had a choice of two ways to put enums in. One was to make them first-class citizens, so that one could do things like defining arrays with enum subscripts and so forth. The other was to fudge them in as a restricted form of integer. I did it the easy but ugly way, and made them restricted integers." -- Henry Spencer @ U of Toronto Zoology {allegra,ihnp4,linus,decvax}!utzoo!henry