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.1 required=5.0 tests=AXB_XMAILER_MIMEOLE_OL_024C2, BAYES_00,MAILING_LIST_MULTI,REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,5037bf0bb33408c8 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-10-08 08:47:02 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!proxad.net!fr.usenet-edu.net!usenet-edu.net!enst.fr!not-for-mail From: "David C. Hoos" Newsgroups: comp.lang.ada Subject: Re: "&" for array versus "&" for Strings Date: Tue, 8 Oct 2002 10:46:39 -0500 Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: References: <200210081153.NAA17399@bulgaria.otn.eurocopter.de> Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: avanie.enst.fr 1034092022 83563 137.194.161.2 (8 Oct 2002 15:47:02 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Tue, 8 Oct 2002 15:47:02 +0000 (UTC) Return-Path: X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.13 Precedence: bulk List-Unsubscribe: , List-Id: comp.lang.ada mail<->news gateway List-Post: List-Help: List-Subscribe: , Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:29592 Date: 2002-10-08T10:46:39-05:00 ----- Original Message ----- From: "Sergey Koshcheyev" Newsgroups: comp.lang.ada To: Sent: Tuesday, October 08, 2002 8:56 AM Subject: Re: "&" for array versus "&" for Strings > > "David C. Hoos, Sr." wrote in message > news:mailman.1034079721.26410.comp.lang.ada@ada.eu.org... > > > > With gnat-3.14p and qualification it still fails, so it would appear that > this > > is a "bug" fixed in 3.16w. Clearly, from a language standpoint, it is > > necessary to disambiguate the & operator in the call to Print_Names, and > > qualification of its operands does just that. > > > > How does it disambiguate the "&"? I would understand if it selected function > "&" (Left, Right : String) return String, but from what you say, it seems > like it made the compiler select function "&" (Left, Right : "String (1 .. > 6)") return Name_Array. That's correct. Without the qualification of its operands, the compiler selects "&" (Left, Right : String) return String, which (correctly) returns an error in 3.16w, but is erroneously accepted by 3.14p. With the qualification of its operands, the compiler selects "&" (Left, Right : String (1 .. 6)) return Name_Array.