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.2 required=5.0 tests=BAYES_00,FROM_DOMAIN_NOVOWEL, 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!watmath!clyde!caip!lll-crg!nike!oliveb!hplabs!sdcrdcf!steve From: steve@sdcrdcf.UUCP (Steven Holtsberg) Newsgroups: net.lang.ada Subject: Ada reference manual inquiry Message-ID: <2929@sdcrdcf.UUCP> Date: Tue, 5-Aug-86 00:08:22 EDT Article-I.D.: sdcrdcf.2929 Posted: Tue Aug 5 00:08:22 1986 Date-Received: Thu, 7-Aug-86 02:42:19 EDT Reply-To: steve@sdcrdcf.UUCP (Steven Holtsberg) Organization: System Development Corporation R&D, Santa Monica List-Id: Perhaps the ARM answers this question somewhere, but I haven't been able to find it. When operators are described, and the ``types'' of their operands are given, do they really mean ``types'', or do they mean ``subtypes''? For example, on page 4-16 (section 4.5.3), when describing ``+'', the manual says that the left operand can be of ``any numeric type'', and the right operand must be of the ``same numeric type''. Do they really mean what I think- that is, in X + Y, if X is a subtype of INTEGER, say POSITIVE, and Y is a another sybtype of INTEGER, say NEGATIVE, then the _type_ of X is INTEGER (although it is of subtype POSITIVE) and the _type_ of Y is INTEGER, so X + Y is legal, and it is of type INTEGER? Or do they mean that X and Y must be of the same subtype, so if X is POSITIVE, then Y must be positive, and X + Y is POSITIVE? More generally, what is the _type_ of any constant or a variable? Is it the subtype it was declared to have, or the base type? Note that on page 3-4, the ARM says that (line 5) the _subtype_ of an object is determined by the object declaration. But, it does not say whether this _subtype_ of the object is also its _type_ of the object, or whether the _type_ of the object is actually the base type. If you know the answer, please also back it up with references in the ARM. Thanks Steven Holtsberg ------------------------------------------------------------- sdcrdcf!steve@ucla-cs or holts@ucla-cs