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=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3a9b49a9162025eb X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-02-13 09:28:08 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!kibo.news.demon.net!demon!shale.ftech.net!news.ftech.net!peernews.cix.co.uk!newspeer1-gui.server.ntli.net!ntli.net!news2.euro.net!ash.uu.net!spool0901.news.uu.net!spool0900.news.uu.net!reader0901.news.uu.net!not-for-mail Date: Thu, 13 Feb 2003 12:27:32 -0500 From: Hyman Rosen User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20030130 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Bye-bye Ada ? (Ada95 Wholesale Changes?) References: <3E3B7BB5.A1A070@adaworks.com> <3NY_9.9226$x63.6255@nwrddc01.gnilink.net> <3E40A07A.CD174746@adaworks.com> <1044457651.769640@master.nyc.kbcfp.com> <3E42A61C.20905@cogeco.ca> <3E432DD4.7F256C85@adaworks.com> <3E43FA31.9873C5AA@adaworks.com> <3E44A869.DDB2352@adaworks.com> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Organization: KBC Financial Products Message-ID: <1045157252.719611@master.nyc.kbcfp.com> Cache-Post-Path: master.nyc.kbcfp.com!unknown@nightcrawler.nyc.kbcfp.com X-Cache: nntpcache 3.0.1 (see http://www.nntpcache.org/) NNTP-Posting-Host: 204.253.250.10 X-Trace: 1045157254 reader1.ash.ops.us.uu.net 22754 204.253.250.10 Xref: archiver1.google.com comp.lang.ada:34062 Date: 2003-02-13T12:27:32-05:00 List-Id: Martin Krischik wrote: > In fact you can't do this if you want virtual inlines. Incorrect as well. You can have a virtual inline with the definition in the class: struct a { virtual void foo() { } }; Perhaps you are thinking of providing an implementation for an *abstract* method: struct a { virtual void foo() = 0; } inline void a::foo() { assert(false, "Strange!"); } It's true in this case that the definition and the '= 0' cannot appear together. > For virtual inlines you have to do it outside the class > definition and you have to provide a non inline version > for the virtual function table. > usualy you it with some ugly #if #endif: This is totally wrong - you really should learn more C++ if you are going to make pronouncements about it. Inline functions don't require any separate definitions for being called indirectly, whether through the virtual table or by having their address taken. The compiler takes care of that.