Re: Enum advice please
Re: Enum advice please
- Subject: Re: Enum advice please
- From: Jeremy Pereira <email@hidden>
- Date: Wed, 7 Jan 2009 11:12:40 +0000
On 6 Jan 2009, at 19:59, Quincey Morris wrote:
I'm sure someone will jump in and correct me if I'm wrong about this,
Jumping in....
but (in answer to the implied "why?" in Graham's post) my
recollection is that:
-- 'typedef' was added to C later in its life, so originally 'enum
XXX' was the only way to refer to an enum type you'd already
defined. ["Later" in this context would be somewhere in the
mid-1970s.] Or perhaps it was just that some C compilers didn't
implement 'typedef' in olden days.
enum was added to C after typedef. When I first started learning C in
the mid 80's (from K & R first edition), typedef already existed as a
keyword but enum didn't. In fact, I don't think enum became an
official part of C until the first ANSI standard was published.
However, your whole discussion still makes sense with the word struct
substituted for enum and I'm sure struct predates typedef.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden