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,83d7c4caadb45100 X-Google-Attributes: gid103376,public From: bobduff@world.std.com (Robert A Duff) Subject: Re: DECAda/VMS - calling GETJPI Date: 1996/06/05 Message-ID: #1/1 X-Deja-AN: 158607030 references: <31B2AF74.668E@dial.eunet.ch> <4p1v56$214@linus.mitre.org> organization: The World Public Access UNIX, Brookline, MA newsgroups: comp.lang.ada Date: 1996-06-05T00:00:00+00:00 List-Id: Robert is correct -- a type conversion of -1 to a modular type will raise C_E. -1 and 255 are *not* the "same mathematical integer". Mike is, perhaps, confused between converting to a *type* and converting to a *subtype*. 4.6(51) says that when converting to a subtype, you first convert to the type, and then do a constraint check. This can, indeed, raise an exception when converting to a non-modular *subtype*, such as Integer. However, when converting to a *type*, the only exceptions are when the target type is modular. Robert's description of the history is correct: an earlier version of Ada 9X did what Mike says, but it was changed. (Robert has a better memory than I as to which meeting that decision was made at, and where the meeting was held.) This language change explains why the Rationale is wrong -- it was simply not updated correctly to match the RM in this case. Nobody is actively working on the Rationale at this point, as far as I know, so this bug in the Rationale will remain unfixed. Bugs in the RM, on the other hand, are addressed by the ARG. There are instructions at the front of the RM telling where to send any comments on the RM, so that the ARG will see them. - Bob