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,6742ab01b9814abe X-Google-Attributes: gid103376,public From: "James A. Squire" Subject: Re: type casting tagged types in the wrong Date: 1996/04/02 Message-ID: <31616B8C.58C5@csehp3.mdc.com>#1/1 X-Deja-AN: 145473512 sender: Ada programming language references: comments: Gated by NETNEWS@AUVM.AMERICAN.EDU content-type: text/plain; charset=us-ascii organization: MDA Avionics Tools & Processes mime-version: 1.0 newsgroups: comp.lang.ada x-mailer: Mozilla 2.0 (X11; I; HP-UX A.09.01 9000/715) Date: 1996-04-02T00:00:00+00:00 List-Id: Scott Moody wrote: > I run this same program with GNAT 3.03 on solaris > and it reports the error correctly: > > tmp.adb:24:14: downward conversion of tagged objects not allowed > gnatmake: *** compilation failed. > > ----source: [source snipped] I just ran it myself against the same compiler on the same platform and to my chagrin I got the same error message. I had figured that the bug would be consistant. The place where I found it was in the Alert system that is partially coded in the Rationale. I added code for the other subunits besides Handle, and then I switched the overloads of Handle so that the one for Medium Alerts called the one for High Alerts instead of the one for Alerts. I made sure the subunit for Set_Alarm actually tried to read the extra field. In this case there was no error on the line: Handle (HA => High_Alert(MA)); I will send this off to report@gnat.com. -- James Squire MDA Avionics Tools & Processes ja_squire@csehp3.mdc.com "one of these days I'm going to better myself by going to Knight school"