Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!linus!genrad!decvax!harpo!floyd!vax135!ariel!hou5f!hou5a!hou5d!hou5e!mat From: mat@hou5e.UUCP Newsgroups: net.lang.c Subject: Re: C typedef deficiency Message-ID: <575@hou5e.UUCP> Date: Thu, 23-Jun-83 21:46:30 EDT Article-I.D.: hou5e.575 Posted: Thu Jun 23 21:46:30 1983 Date-Received: Sat, 25-Jun-83 01:37:47 EDT Lines: 44 Well, regarding the enum's ... I don't think that there would be much, if any efficieny difference over, say, #defines. They are, if well implemented in a language, one more good way to aid communication and make strong typing available to the programmer when she thinks that it is needed. Ada has some good ideas here ... the disambiguate in the case of (hope this is close to being right .. I DON'T use enum's) typedef enum ( RED, GREEN, ROTTEN ) APPLES; typedef enum ( FLORIDA, CALIFORNIA, ROTTEN ) ORANGES; one would write APPLES.ROTTEN or ORANGES.ROTTEN. ADA (Yes, a TM of US DOD, et&c) has a LOT of good ideas. Also a few very bad ones, and in critical places. And a lot of other problems (which should get discusssed in net.lang). One area that received a lot of attention (ie nitpicking from academia) was disambiguation in various forms. If there is a successor to C I hope that its designers use the good stuff out of ADA, just as (it seems) C used good stuff from the FORTRAN/PL\/1 heritage. I don't think enums, as implemented, are either well enough designed or well enough implemented to be integrated into one's standard repertoire of C constructs and techniques. (My opinions only ... they should not be construed to represent opinions of either my employer or client) Mark Terribile (sometime Duke of deNet) Spiridellis & Associates (A member of the Cap Gemini Sogetti USA Group) On contract at American Bell, Holmdel hou5e!mat