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.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.98.26.8 with SMTP id a8mr6685989pfa.4.1472146117447; Thu, 25 Aug 2016 10:28:37 -0700 (PDT) X-Received: by 10.157.31.88 with SMTP id x24mr814966otx.4.1472146117408; Thu, 25 Aug 2016 10:28:37 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!news.glorb.com!f6no12930158ith.0!news-out.google.com!d68ni38767ith.0!nntp.google.com!f6no12930154ith.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 25 Aug 2016 10:28:37 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=149.32.224.37; posting-account=Qh2kiQoAAADpCLlhT_KTYoGO8dU3n4I6 NNTP-Posting-Host: 149.32.224.37 References: <68b89d71-dd92-4b9c-adb9-476a7caa64cf@googlegroups.com> <8955f6b0-18c6-41b9-91bf-b756189f53db@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Subtype predicates From: Anh Vo Injection-Date: Thu, 25 Aug 2016 17:28:37 +0000 Content-Type: text/plain; charset=UTF-8 Xref: news.eternal-september.org comp.lang.ada:31566 Date: 2016-08-25T10:28:37-07:00 List-Id: On Wednesday, August 24, 2016 at 5:31:28 PM UTC-7, Jeffrey R. Carter wrote: > On 08/24/2016 05:08 PM, Shark8 wrote: > > > > Hm, another argument for a 'Type attribute, then we could say > > > > type Human_Life_Span is range 0 .. 130 > > with Default_Value => Human_Life_Span'Type'First; > > Perhaps. The ARG seem leary of adding features where there's a work around, and Yes, there are a number of ways to work around. Here is my preferred way Min_Age : constant := 0; Max_Age : constant := 130; type Human_Life Span_Type is new Integer range Min_Age .. Max_Age with Default_Value => Min_Age; Anh Vo