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=-2.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,436e4ce138981b82 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-03-06 11:15:35 PST Path: archiver1.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!crtntx1-snh1.gtei.net!chcgil2-snh1.gtei.net!news.bbnplanet.com!nycmny1-snf1.gtei.net!news.gtei.net!colt.net!news.tele.dk!news.tele.dk!small.news.tele.dk!proxad.net!usenet-fr.net!enst.fr!melchior!cuivre.fr.eu.org!melchior.frmug.org!not-for-mail From: Marius Amado Alves Newsgroups: comp.lang.ada Subject: Re: abstract sub programs overriding Date: Sat, 6 Mar 2004 19:09:03 +0000 Organization: Cuivre, Argent, Or Message-ID: References: <5f59677c.0403021101.4ac263d0@posting.google.com> <5f59677c.0403060718.3d6aa909@posting.google.com> NNTP-Posting-Host: lovelace.ada-france.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Trace: melchior.cuivre.fr.eu.org 1078599906 71787 212.85.156.195 (6 Mar 2004 19:05:06 GMT) X-Complaints-To: usenet@melchior.cuivre.fr.eu.org NNTP-Posting-Date: Sat, 6 Mar 2004 19:05:06 +0000 (UTC) To: comp.lang.ada@ada-france.org Return-Path: X-Mailer: KMail [version 1.3.2] In-Reply-To: <5f59677c.0403060718.3d6aa909@posting.google.com> X-OriginalArrivalTime: 06 Mar 2004 19:04:41.0707 (UTC) FILETIME=[E1488BB0:01C403AD] X-Virus-Scanned: by amavisd-new-20030616-p7 (Debian) at ada-france.org X-BeenThere: comp.lang.ada@ada-france.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: "Gateway to the comp.lang.ada Usenet newsgroup" List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Xref: archiver1.google.com comp.lang.ada:6109 Date: 2004-03-06T19:09:03+00:00 > if i have overriden generate at a higher lever even if it is for an > asbtract type, this should not raise any problem. am i wrong? Sorry, I don't understand the question. It's very simple, really: you can only call concrete, and of course available, operations. In your program you had an abstract (not concrete) Generate (for a 'root' type), and a concrete, but not available Generate (for a derived type). The concrete Generate was not available (at the point of the call) because it was declared in the private part of a separate unit. So the first was available but was not concrete, the second was not available, GNAT went for the only available one, and naturally failed, mumbling whatever GNAT mumbles when it tries to call an abstract operation.