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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,2e6723b897ab47fb X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.66.85.136 with SMTP id h8mr1807500paz.46.1344329173493; Tue, 07 Aug 2012 01:46:13 -0700 (PDT) Path: c10ni91079pbw.0!nntp.google.com!news1.google.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: Marius Amado-Alves Newsgroups: comp.lang.ada Subject: Re: Ada.Locales pseudo-string types Date: Tue, 7 Aug 2012 01:44:37 -0700 (PDT) Organization: http://groups.google.com Message-ID: <257b4f44-b6c6-4c79-8c6e-dec947a3ce25@googlegroups.com> References: <78707b6e-88a3-453a-a37c-840f7a62e703@googlegroups.com> <7303f906-0f6a-4d97-ae15-36b4056ede6c@googlegroups.com> NNTP-Posting-Host: 188.82.45.163 Mime-Version: 1.0 X-Trace: posting.google.com 1344329173 28605 127.0.0.1 (7 Aug 2012 08:46:13 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 7 Aug 2012 08:46:13 +0000 (UTC) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=188.82.45.163; posting-account=3cDqWgoAAAAZXc8D3pDqwa77IryJ2nnY User-Agent: G2/1.0 Content-Type: text/plain; charset=ISO-8859-1 Date: 2012-08-07T01:44:37-07:00 List-Id: On Tuesday, August 7, 2012 12:07:02 AM UTC+1, Adam Beneschan wrote: > I just sent a note to Ada-Comment requesting that To_String and From_String operations be added to Ada.Locales. Maybe that isn't the right solution, but it does seem like something needs to change. What needs to change is the language doing the obvious thing: if types are compatible (down to no any level of composition) then they are convertible. I was pretty sure arrays of convertible elements were convertible and I am much surprised to find they are not and I am still not convinced that this is not a compiler bug. If it is a language limitation, then before 20X0 lifts it, is not there an aspect clause to restrict the character range with the array being a subtype of string? subtype Language_Code is String (1 .. 2) with Component_Range in 'a' .. 'z'; (Instead of adding To/From_String functions.)