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,45a9122ddf5fcf5 X-Google-Attributes: gid103376,public From: kilgallen@eisner.decus.org (Larry Kilgallen) Subject: Re: Rules for Representation of Subtypes Date: 1996/10/01 Message-ID: <1996Oct1.100608.1@eisner>#1/1 X-Deja-AN: 186466133 x-nntp-posting-host: eisner.decus.org references: <1996Sep26.191257.1@eisner> <52hnvh$li0@wdl1.wdl.lmco.com> x-nntp-posting-user: KILGALLEN x-trace: 844178772/23494 organization: LJK Software newsgroups: comp.lang.ada Date: 1996-10-01T00:00:00+00:00 List-Id: In article , bobduff@world.std.com (Robert A Duff) writes: > The point is that you should convert to a type that "fills all the > bits". That is, there are no possible bit patterns that don't represent > valid data. Then, *after* the unchecked conversion, you can do an > assignment that does a constraint check. Checking Y'Valid in the above > example would not help, since the program is already erroneous. The > 'Valid feature is just like anything else -- it won't work as advertised > if the execution is already erroneous. So can someone give an example of how Z'Valid _might_ be useful after an unchecked conversion, as seems to be indicated by the Reference Manual. Larry Kilgallen