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: a07f3367d7,ae8b13d4d815893c X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!h23g2000vbc.googlegroups.com!not-for-mail From: christoph.grein@eurocopter.com Newsgroups: comp.lang.ada Subject: Re: (Num_Types.Mod_4 range 1..8) ------->why not (1..8)? Date: Mon, 18 May 2009 23:26:16 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <0571282b-0ab8-4eee-941f-e9369f5b4518@x6g2000vbg.googlegroups.com> <4a11b8cb$0$32680$9b4e6d93@newsspool2.arcor-online.net> <6b5fe400-2564-4fc9-a5bf-f83d1e476345@q14g2000vbn.googlegroups.com> <4a11cae4$0$32667$9b4e6d93@newsspool2.arcor-online.net> <03cb75a1-3458-420e-9871-6f64f784c177@s38g2000prg.googlegroups.com> NNTP-Posting-Host: 80.156.44.178 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: posting.google.com 1242714376 30570 127.0.0.1 (19 May 2009 06:26:16 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 19 May 2009 06:26:16 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: h23g2000vbc.googlegroups.com; posting-host=80.156.44.178; posting-account=rmHyLAoAAADSQmMWJF0a_815Fdd96RDf User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; InfoPath.1; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729),gzip(gfe),gzip(gfe) X-HTTP-Via: 1.1 webwasher (Webwasher 6.8.3.4555) Xref: g2news2.google.com comp.lang.ada:5930 Date: 2009-05-18T23:26:16-07:00 List-Id: While re-hosting some code, yesterday I bumped into some code like so: type Some_Array is array (Some_Index range <>) of Some_Type; subtype Small_Array is Some_Array (1 .. 8); subtype Max_Array is Some_Array (1 .. Some_Index'Last); function Convert is Unchecked_Conversion (Source => Small_Array, Target => Max_Array); Guess what the perpetrator told me was the reason for this abomination: The compiler complained when he assigned an object of Small_Array to one of Max_Array. So he found this "solution"...