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,FREEMAIL_FROM, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a59300e1cca1082c X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-09-19 14:42:38 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!netnews.com!xfer02.netnews.com!solaris.cc.vt.edu!news.vt.edu!msunews!not-for-mail From: "Chad R. Meiners" Newsgroups: comp.lang.ada Subject: Re: Safe C++ Date: Wed, 19 Sep 2001 17:38:32 -0400 Organization: Michigan State University Message-ID: <9ob2u6$2r4l$1@msunews.cl.msu.edu> References: <3BA7A45D.186EE27A@adaworks.com> <20010919072904.O10277-100000@shell5.ba.best.com> <20010919102107.L4954-100000@shell5.ba.best.com> Reply-To: "Chad R. Meiners" NNTP-Posting-Host: arctic.cse.msu.edu X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700 Xref: archiver1.google.com comp.lang.ada:13191 Date: 2001-09-19T17:38:32-04:00 List-Id: "Brian Rogoff" wrote in message news:20010919102107.L4954-100000@shell5.ba.best.com... > On Wed, 19 Sep 2001, Chad Robert Meiners wrote: > > On Wed, 19 Sep 2001, Brian Rogoff wrote: > > > Rather than just snipe from the side at people trying to do better, take > > > a look at > > > > > > http://www.cs.cornell.edu/projects/cyclone/ > > > > > > and consider that it certainly has some features which are arguably better > > > than the Ada alternatives. > > > > Which features are better than the Ada alternatives? > ^-- arguably > > Pattern matching > Parametrically polymorphic functions > Tuples I'll have to trust you or these three since I have never encountered a situation where I was ever wishing for such functionality. The examples in Cyclone's documentation gave me the impression that they are useful to C programmer because they definitely add value to the C syntax. I just don't see how they would add value to Ada's syntax. Perhaps if you could tell me why it would be useful to you to have them incorporate into Ada, I could their the significance of the value added. > I think region based memory management is a win too, and could probably be > fit onto Ada without too much disruption. I am pretty sure that when an access type falls out of scope in Ada, any storage pools associated with it may be deallocated. This seems pretty close to what regions do? > > Cyclone doesn't appear to help reduce the number of pointers that the > > programmer has to manage which I consider to be a major drawback with the > > language. > > Ada has advantages here, no doubt, but Cyclone makes the manipulations > much safer than C or C++. It's hardly fair to compare the unsafety of > Cyclone pointers with raw C! > > As much as I prefer Ada to C, it's clear that some of these Safer C/C++ > variants, especially ones which don't try to follow C++ too much, have a > lot to offer. Ada advocates can start seeming awfully provincial, with > their allergies to anything smacking of C. One of the major flaws with deriving something better out of C is that it is comparable to trying to build a nice boat out of a cheaply built one. Sure it is possible to do this but either a) you will end up scraping the boat and rebuilding it entirely, or you will have to live with a ship that is inconsistently built after doing a lot of work patching all of the *known* 'design flaws'. Consistency is very important in a language. Ada is wonderfully consistent whereas I have my doubts with these 'Safer C/C++'s. I don't believe that you will find very many Ada advocates that have an allergy to anything smacking of C. I have always been under the impression that people on this newsgroup are open to discuss suggestions for the language. > Now, if you were to complain that Cyclone is another one of these > miserable flat languages without nested function definitions, I'd cheer > you on. :-) Although flatness is a burden, it is less so than unnecessary pointers. > -- Brian > > > > > Putting my "Ada fan" hat on, I'd say that some of the work on region based > > > memory management should find it's way into some Ada dialect, maybe even > > > into the standard. And I really think pattern matching and some other > > > features of modern (read HM-typed, functional/declarative) languages > > > should find their way into an Ada successor. If only the Cyclone guys had > > > started with Ada, or even the SPARK subset! > > > > > > It's really unfortunate that Ada hasn't spawned lots of research > > > dialects, like C family languages have. > > > > > > -- Brian > > > > > > > > > > > - Chad R. Meiners > > > > >