Grouse: What's the point of enum?
Rogue Winter
rogue at cellar.UUCP
Thu Apr 25 03:51:17 AEST 1991
ts at cup.portal.com (Tim W Smith) writes:
> Wow! Both Henry Spencer and Chris Torek missed the point of enumerated
> types... next thing you know, getting involved in a land war in Asia
> will be a good idea.
>
> Anyway, the real point is to allow lower case names for constants. If
>
[code deleted, The President's previous statements are inoperable]
> people who read the code will be so busy trying to remember what the
> heck and 'enum' is that they won't realize you've snuck in lower case
> constant names.
>
> Tim Smith
Well, since I'm self-taught and don't have anyone looking over my shoulder at
my bad habits, I tend to violate such canons amyhow. I've used all caps to
define constants and mixed case to define macros and nobody else has ever had
to know the wiser. (oops, now I've just blurted it out)
Since the only reason I sould come up with for using enums was as an
alternate declaration of constants, I had to consider it useless, since it
takes more expressions to use an enum variable than a defined constant.
Rogue Winter : "How can you say I only protected people in South
rogue at cellar.uucp : Philadelphia? I protected people all over this city; it
uunet!cellar!rogue: didn't matter if they were in South Philadelphia or
Cellar 215/3369503: Northeast Philadelphia." -- Frank Rizzo, 4/12/91
More information about the Comp.lang.c
mailing list