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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,115cdbb394b3e615 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!irazu.switch.ch!switch.ch!news.belwue.de!news.uni-stuttgart.de!carbon.eu.sun.com!btnet-feed5!btnet!news.btopenworld.com!not-for-mail From: Martin Dowie Newsgroups: comp.lang.ada Subject: Re: Why can't you create a out of order subtype? Date: Wed, 2 Feb 2005 21:18:36 +0000 (UTC) Organization: BT Openworld Message-ID: References: <1107301914.648240.237290@g14g2000cwa.googlegroups.com> NNTP-Posting-Host: host81-154-188-69.range81-154.btcentralplus.com Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: titan.btinternet.com 1107379116 3946 81.154.188.69 (2 Feb 2005 21:18:36 GMT) X-Complaints-To: news-complaints@lists.btinternet.com NNTP-Posting-Date: Wed, 2 Feb 2005 21:18:36 +0000 (UTC) In-Reply-To: X-Accept-Language: en-us, en User-Agent: Mozilla Thunderbird 1.0RC1 (Windows/20041201) Xref: g2news1.google.com comp.lang.ada:8140 Date: 2005-02-02T21:18:36+00:00 List-Id: Marius Amado Alves wrote: >>> declare >>> M : Msg := Whatever; >>> V : Vowelmsg; >>> begin >>> V := Vowelmsg'Value (Msg'Image (M)); >>> -- if control reaches here then M is a vowel >>> exception >>> when Constraint_Error => -- M is not a vowel >>> end; >> >> >> That's very, very, very slow... > > > No, it's only very, very slow :-) > > If (and only if :-) that's too slow for the application then sure, use > UC and 'Valid. And watch out for those uninitialized variables. > "pragma Normalize_Scalars;" :-)