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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,4ff929aa5c2b2834 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail From: "Dmitry A. Kazakov" Subject: Re: Ranges and (non)static constraints Newsgroups: comp.lang.ada User-Agent: 40tude_Dialog/2.0.15.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reply-To: mailbox@dmitry-kazakov.de Organization: cbb software GmbH References: Date: Thu, 16 Nov 2006 14:13:58 +0100 Message-ID: <1pqs0gcno5o2t.1195tm9yap28b.dlg@40tude.net> NNTP-Posting-Date: 16 Nov 2006 14:13:58 CET NNTP-Posting-Host: d2bbc732.newsspool4.arcor-online.net X-Trace: DXC=bYY]jeVVk^Y[7Non7UCi8U4IUK On Thu, 16 Nov 2006 12:02:15 +0100, Maciej Sobczak wrote: > type T is range 1 .. N; > type U is new Integer range 1 .. M; > > N must be static, but M does not have to. > Why and what is the real difference between T and U? Informally, the second is an abbreviation for: type is new Integer; subtype U is range 1..M; so "range" refers to a subtype. On the contrary, in the first, "range" refers a type. So the difference. Is it real? I don't think so. I would eliminate this difference between types and subtypes by allowing the latter to have a different representation than the base. So the first should be also an abbreviation for type is new Universal_Integer; subtype T is range 1..N; That would make both legal (or, maybe, illegal (:-)). -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de