From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ca9eef4d5e2078ea X-Google-Attributes: gid103376,public From: dewar@merv.cs.nyu.edu (Robert Dewar) Subject: Re: Beware: Rep spec on an enumeration type causes code explosion Date: 1997/12/10 Message-ID: #1/1 X-Deja-AN: 296823001 References: <66j5r6$ck1$1@gonzo.sun3.iaf.nl> X-Complaints-To: usenet@news.nyu.edu X-Trace: news.nyu.edu 881730533 10877 (None) 128.122.140.58 Organization: New York University Newsgroups: comp.lang.ada Date: 1997-12-10T00:00:00+00:00 List-Id: Joe Gwinn wrote: ``A number of folk have cited chapter and verse that enumerations do start at zero if left alone. This was not widely known, apparently, perhaps because Ada83 didn't govern this.'' Well it is not easy to gauge what is or is not "widely known", or even what such a phrase means. But I have never seen an Ada 83 compiler which did not default to Pos value = representation value, and any other choice would be strange indeed. Yes, Ada 95 makes this explicit, but this is not a requirement that I would expect to have any effect on implementations in practice, because no other choice makes sense. And certainly all the Ada programmers I have known were aware of this as the natural and likely default!