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.7 required=5.0 tests=BAYES_00,INVALID_DATE, MSGID_SHORT,REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!rutgers!rochester!udel!burdvax!sdcrdcf!sdcsmb!dim!steve From: steve@dim.sm.unisys.com (Steven Holtsberg) Newsgroups: comp.lang.ada Subject: 2nd follow-up to my previous posting (Re: RM question concerning types) Message-ID: <23@dim.sm.unisys.com> Date: Mon, 23-Nov-87 20:46:35 EST Article-I.D.: dim.23 Posted: Mon Nov 23 20:46:35 1987 Date-Received: Fri, 27-Nov-87 05:21:46 EST References: <21@dim.sm.unisys.com> <22@dim.sm.unisys.com> Reply-To: steve@dim.sm.unisys.com (Steven Holtsberg) Organization: Unisys Santa Monica List-Id: In article <22@dim.sm.unisys.com> steve@dim.sm.unisys.com (I) write: >I believe that if the following slight change were made to the reference >manual, it would be OK. > >RM 3.5 > >For any scalar type T or for any subtype T of a scalar type, the >following attributes are defined: 7 > >T' FIRST Yields the lower bound of T. The value of this attribute > has the same base type as T. > ^^^^ >T' LAST Yields the upper bound of T. The value of this attribute > has the same base type as T. > ^^^^ I was wrong. In (RM) 3.3, it is stated that the base type of a type is the type itself. So, changing "type" to "base type" does not change the above sentences. Therefore, T, declared by type T is range l..r must be a subtype, not a type. If T is taken as a subtype, then the description in RM 3.5 is OK. Now, the only question is why do they allow declaration of such static subtypes? (E.g., type T is range l..r instead of subtype T is integer_type range l..r). The only reason I can think of is to allow the particular implementation to choose which base type to use--which of course, leads to non-portable code.