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.3 required=5.0 tests=BAYES_00,FREEMAIL_FROM, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,fb4dd933ef563a8,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-07-05 10:08:34 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!nycmny1-snh1.gtei.net!cambridge1-snf1.gtei.net!news.gtei.net!bos-service1.ext.raytheon.com!bos-service2.ext.raytheon.com.POSTED!not-for-mail Message-ID: <3D25D271.ACE6DAC8@despammed.com> From: Wes Groleau Reply-To: wesgroleau@despammed.com X-Mailer: Mozilla 4.77 [en] (Windows NT 5.0; U) X-Accept-Language: en,es-MX,es,pt,fr-CA,fr MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: When/Why can a compiler reject an operator but accept a name? Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Fri, 05 Jul 2002 12:08:01 -0500 NNTP-Posting-Host: 151.168.144.162 X-Complaints-To: news@ext.ray.com X-Trace: bos-service2.ext.raytheon.com 1025888913 151.168.144.162 (Fri, 05 Jul 2002 13:08:33 EDT) NNTP-Posting-Date: Fri, 05 Jul 2002 13:08:33 EDT Organization: Raytheon Company Xref: archiver1.google.com comp.lang.ada:26879 Date: 2002-07-05T12:08:01-05:00 List-Id: In package G I have: type List_Type is array (Natural range <>) of Item; type Order is access function (Left, Right : in Item) return Boolean; procedure Sort (List : in out List_Type; Sequence : in Order); In procedure P I had: package I is new G (Item); function "<" (Left, Right : in Item) return Boolean is ..... I.Sort (List => List, Sequence => "<"'Access); Compiler rejected it, saying: "<" has no definition that matches function (Left, Right : in Item) return Boolean [RM_95 3.10.2(32)] I replaced "<" with Ord_Check (no other changes), and the compiler accepted it. Does using an operator instead of a name make the function Intrinsic? If not, there is no support for rejection in 3.10.2(32) Is there any reason elsewhere in the RM to justify this odd behavior? (Certainly either way, the message could be improved!) -- Wes Groleau http://freepages.rootsweb.com/~wgroleau