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.4 required=5.0 tests=AC_FROM_MANY_DOTS,BAYES_00 autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9d8db3defac005a2 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-11-18 03:16:21 PST From: Egil Harald Hoevik Newsgroups: comp.lang.ada Subject: Re: Renaming an abstract function Date: Sat, 17 Nov 2001 18:47:21 +0100 Organization: Kongsberg Group ASA , Norway Message-ID: <3BF6A2A9.C50750D5@kongsberg.com> References: <9t1lp1$16unne$1@ID-25716.news.dfncis.de> NNTP-Posting-Host: 150.1.30.135 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.72 [en] (X11; I; SunOS 5.8 sun4u) X-Accept-Language: en Path: archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!news.algonet.se!algonet!newsfeed1.bredband.com!bredband!uio.no!Norway.EU.net!193.71.169.73!spiten.kongsberg.com!kongsberg!not-for-mail Xref: archiver1.google.com comp.lang.ada:16668 Date: 2001-11-17T18:47:21+01:00 List-Id: Adam Beneschan wrote: > > A "callable entity" is defined (in 6(2)) to be a subprogram or entry. > Thus an abstract subprogram is a callable entity even though you can't > really call it. > RM 6 (1): "...The definition of a subprogram can be given in two parts: a subprogram declaration defining its interface, and a subprogram_body defining its execution..." So, a subprogram (callable entity) requires a body (callable construct), while an abstract subprogram does not, and the RM distinguishes between the two: RM 6.1 (2-3): subprogram_declaration ::= subprogram_specification; abstract_subprogram_declaration ::= subprogram_specification is abstract; > I don't see any prohibition on renaming an abstract subprogram. > However, renaming subprograms don't quite take on all the > characteristics of the subprograms they rename; see 8.5.4(12) for > instance. I suspect that has something to do with why renaming an > abstract subprogram could lead to an error, but I don't have time > right this minute to look into it further. > > -- Adam Well, RM 8.5.4 (2): subprogram_renaming_declaration ::= subprogram_specification renames callable_entity_name; If renaming an abstract subprogram were allowed, I, at least, would think that the language would explicitly require the keyword 'abstract' in the renaming declaration (which it does not). ~egilhh -- "What I seek is to serve, with my feeble capacity, truth and justice at the risk of pleasing no-one." Albert Einstein.