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, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,c406e0c4a6eb74ed X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!news.glorb.com!news.zanker.org!newsfeed00.sul.t-online.de!newsmm00.sul.t-online.de!t-online.de!news.t-online.com!not-for-mail From: Martin Krischik Newsgroups: comp.lang.ada Subject: Re: ADA Popularity Discussion Request Date: Thu, 02 Sep 2004 09:59:00 +0200 Organization: AdaCL Message-ID: <1195965.KqRhyO6tpe@linux1.krischik.com> References: <49dc98cf.0408110556.18ae7df@posting.google.com> <1198227.gWQ0keDDOY@linux1.krischik.com> <1093956169.632925@master.nyc.kbcfp.com> <4ic2hc.1q.ln@skymaster> <1093983432.462543@master.nyc.kbcfp.com> Reply-To: krischik@users.sourceforge.net Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: news.t-online.com 1094124121 02 8437 rcaaXW+6edmofcA 040902 11:22:01 X-Complaints-To: usenet-abuse@t-online.de X-ID: S1ztUiZ1reCJIIyWkz-b538NIFgzd2d2gMD1KRHgi5u5mb4fso3mkv User-Agent: KNode/0.7.7 Xref: g2news1.google.com comp.lang.ada:3256 Date: 2004-09-02T09:59:00+02:00 List-Id: Hyman Rosen wrote: > Jean-Pierre Rosen wrote: >> If I'm not mistaken, last time I looked at C++ such inner types had >> local visibility, but still global scope. Not the same thing as truly >> "local" classes. Correct me if I'm wrong. > > It's not a terribly meaningful distinction for C++. > In C++ types do not have any runtime dependencies > the way they can in Ada, and therefore they also do > not any notion of lifetime or extent. So in that > sense, all types are global. But they are local in > the sense that you can declare them where you need > them, like my example. > >> Inner classes are classes within classes (same as package inside >> package, which Ada of course allows), not classes inside functions. > > Anonymous classes are a type of inner class, and they most certainly > can be declared/created within functions. Please see this reference: > . But that is only a syntax -hack for lazy typers. The so called "local" classes are actualy global classes with special naming convention - usualy invoving a "$" in the middle of the name. With Regards Martin -- mailto://krischik@users.sourceforge.net http://www.ada.krischik.com