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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,43aafc250d42730f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-02-09 09:01:59 PST Path: supernews.google.com!sn-xit-02!sn-xit-03!supernews.com!news-out.usenetserver.com!sjc-peer.news.verio.net!news.verio.net!sjc-read.news.verio.net.POSTED!not-for-mail Newsgroups: comp.lang.ada From: Brian Rogoff Subject: Re: controlled type in generic package? In-Reply-To: <871yt8rvhq.fsf@deneb.enyo.de> Message-ID: References: <3A7FDA9A.C667090F@stn-atlas.de> <95p2ab$463$1@nnrp1.deja.com> <95sgl2$3c8$1@wanadoo.fr> <871yt8rvhq.fsf@deneb.enyo.de> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Date: Fri, 09 Feb 2001 17:02:25 GMT NNTP-Posting-Host: 206.184.139.136 X-Complaints-To: abuse@verio.net X-Trace: sjc-read.news.verio.net 981738145 206.184.139.136 (Fri, 09 Feb 2001 17:02:25 GMT) NNTP-Posting-Date: Fri, 09 Feb 2001 17:02:25 GMT Organization: Verio Xref: supernews.google.com comp.lang.ada:5073 Date: 2001-02-09T17:02:25+00:00 List-Id: On 9 Feb 2001, Florian Weimer wrote: > Brian Rogoff writes: > > Yes, C++, Java and Eiffel are fairly "flat" languages, like Python and > > unlike Ada. > > Python permits class declarations anywhere a statement is allowed (in > fact, a class declaration *is* a statement). Python classes are > usually used to implement closures: [...snip...] > Python is not a flat language at all. Unless it has changed since I last used it (~ v1.5), Python does not have nested scopes, so it's relatively flat. Even C has nested scopes, just not nested function definitions. Ada allows you to define classes at arbitrarily deep levels of scope. Python doesn't even allow you to create deeper levels of scope. OK, I just hit the Python page and http://python.sourceforge.net/peps/pep-0227.html http://www.amk.ca/python/2.1/index.html#SECTION000300000000000000000 confirm that 2.1 will no longer be a "flat" language. -- Brian