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!news2.google.com!proxad.net!gatel-ffm!gatel-ffm!newsfeed.vmunix.org!feed.news.tiscali.de!newsfeed01.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 18:32:07 +0200 Organization: AdaCL Message-ID: <3424935.PxAL33rWXq@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> <1195965.KqRhyO6tpe@linux1.krischik.com> <1094132006.886791@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 1094149661 05 29176 1IhaXyMJCylwQvM 040902 18:27:41 X-Complaints-To: usenet-abuse@t-online.de X-ID: boxM9vZF8e7p99p2G3513h0JreWdkDCW3wPx7QqiefbnoNSQpKypEj User-Agent: KNode/0.7.7 Xref: g2news1.google.com comp.lang.ada:3269 Date: 2004-09-02T18:32:07+02:00 List-Id: Hyman Rosen wrote: > Martin Krischik wrote: >> 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. > > This discussion started when JPR said > However, all other OO languages (that I know of) require > *all* classes to be declared at library level. > > This is demonstrably untrue (unless JPR knows of neither C++ nor Java); > Java and C++ do allow classes to be declared other than at library level, > including inside functions. Neither C++ nor Java has Pascal-like block > structure, so these local classes interact more weakly with their > declaration environment than would be the case otherwise, but they are > nevertheless locally declared. Because of this weaker interaction, types > in C++ and Java do not have or need a lifetime, so they are global in > that sense, but not in a name lookup sense. But my argument is: "Java cheats". You declare at local level, but you get library level. Have a look at the following list: -rw-rw----+ 1 2,7K 2004-09-01 13:42 Empfangen.class -rw-rw----+ 1 1,1K 2004-09-01 13:42 Empfangen$My_Authenticator.class -rw-rw----+ 1 991 2004-09-01 13:42 Empfangen$Nachricht.class -rw-rw----+ 1 1,2K 2004-09-01 12:46 Messages.class -rw-rw----+ 1 132 2004-09-01 13:28 messages.properties -rw-rw----+ 1 2,2K 2004-09-01 13:45 Senden.class The so called "local" classes even get there own files. With Regards Maritn -- mailto://krischik@users.sourceforge.net http://www.ada.krischik.com