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=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.182.24.70 with SMTP id s6mr27819808obf.42.1436555442905; Fri, 10 Jul 2015 12:10:42 -0700 (PDT) X-Received: by 10.182.213.199 with SMTP id nu7mr176372obc.39.1436555441837; Fri, 10 Jul 2015 12:10:41 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!news.glorb.com!i4no699799ige.0!news-out.google.com!t2ni6555igk.0!nntp.google.com!qs7no3572616igc.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 10 Jul 2015 12:10:41 -0700 (PDT) In-Reply-To: <87mvz36fen.fsf@jester.gateway.sonic.net> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2602:306:3784:5b10:5cd9:867b:597a:c5b9; posting-account=yiWntAoAAAC1KqC_shmxJYv07B9l6LNU NNTP-Posting-Host: 2602:306:3784:5b10:5cd9:867b:597a:c5b9 References: <14592326-5070-4663-a864-5684298f3748@googlegroups.com> <004361da-53c4-4ea9-8cc6-38944aa6c7ad@googlegroups.com> <29dd5458-f9ce-4db8-9128-8ab35a9ce5f8@googlegroups.com> <64bc671c-72e5-4924-b703-3b907c69949c@googlegroups.com> <877fq9uj6g.fsf@theworld.com> <65061686-5c8f-433b-9b11-9e228298158e@googlegroups.com> <87k2u96jms.fsf@jester.gateway.sonic.net> <06f8a6f9-d219-4d40-b9ac-8518e93839bd@googlegroups.com> <87y4io63jy.fsf@jester.gateway.sonic.net> <7a29d3e9-d1bd-4f4a-b1a6-14d3e1a83a4d@googlegroups.com> <87mvz36fen.fsf@jester.gateway.sonic.net> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <2215b44f-8a89-47c6-a4c4-52b74d2dac45@googlegroups.com> Subject: Re: If not Ada, what else... From: David Botton Injection-Date: Fri, 10 Jul 2015 19:10:42 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: news.eternal-september.org comp.lang.ada:26750 Date: 2015-07-10T12:10:41-07:00 List-Id: > I think Ada is somewhat rehabilitated now, partly because of Ada 2012. > I was aware of SPARK before that, when it was a separate expensive tool > from a specialty vendor. Without it, Ada was just a clumsy and > bureaucratic Pascal-like language. I got much more interested in using > it when it became part of the GNAT collection. So now an expensive vendor tool is still an expensive vendor tool and SPARK is thought to be an extension of a clumsy bureaucratic Pascal like language...... Sounds like things got worse. > There's nothing like that for D. Nope. Nor does Ada. SPARK does. > Are there tools like SPARK for statically verifying the D annotations? We are talking about Ada not SPARK. If you like SPARK and it fits your needs great. > I may be missing something here, but I don't see where Ada's type system > is that much better than C++'s, So in C++ you can create new incompatible types with various ranges, use them for array indexes, true enums? > and it's way behind Haskell's. Different, but also something to investigate for Ada. > Ranged > types are useful but you can implement them (with runtime checks) in > other languages. That is what you don't understand, Ada is about compile time checks and that comes with contacts. Contracts on the types, contracts on the interfaces. > They're interesting in Ada 2012 mostly because of the > possibility of checking them statically with Spark. And why mostly of little interest to me. > Another big advantage of Ada is much more precisely defined semantics > than C++'s. To quote another poster, the Ada community has put colossal > effort into certifying compilers and solidifying the standard. Well, once upon a time Ada compilers were certified. I don't believe AdaCore does that anymore. In the end of the day they are the only vendor and so they are the standard.... > I don't > know how D fares in this comparison. Actually I'd say today D and Ada are again in the same boat. > There are generally ways to program without a GC, but if your > application constraints allow you to use one, it can make your code > simpler and more maintainable, as well as speeding development. And if you use Ada long enough you learn to use the Stack most of the time to accomplish the same thing and you don't get sloppy which tends to happen to GC dependent programmers. > Are you > programming to solve puzzles or are you trying to get a task > accomplished? If you like puzzles, try Forth ;-). If you know your tools you use them, Ada is an excellent tool that helps mold your code as you go in to solving problems in reusable and reliable ways. It is why I use Ada for "hacking" I've actually written software in Forth. It had its place in the days of tight memory constraints. > Ada with a GC would be interesting and in a different category but it > would lose its suitability for constrained, realtime environments. At > that point it's competing with Java (and Java's offspring like Scala) Ada does have a GC in some implementations as I pointed out. You are having trouble separating language from runtime environment. A GC in Ada or D is something you can choose to use. BTW, I've never had the need but there are ways to use a GC even the current GNAT's on most platforms. A GC doesn't change the language unless the language requires its use. Neither Ada or D does so. > I guess in my world, any non-GC'd language is niche (it's used for > either small embedded environments, high-assurance realtime, or > maximizing performance like for numerics or big network servers). For > the general purpose middle ground, current trends are toward GC'd > languages that support functional-programming idioms, which Ada isn't so > hot at. You can use D in that environment, although Ada is better at it. Repl clauses, etc. are also pluses. > I think Ada is an attractive choice for lots of things that people > (including me) are currently doing with C and C++, but I consider those > to be niche languages today too (unlike 20 years ago). No still general purpose. You need to look at the language itself to make that determination not just how it is being used currently. C and C++ are still heavily used in general use cases, from embedded to UI and Game Dev, etc. If anything C#, Python, Java are more niche, just their niche is where the vast majority of programs and programmers are. You would be a fool to use any of the three in anything critical (safety, time, etc.) Even Haskell, OCAML, etc. are fairly niche. All he scripting languages are niche. Ada, D, C, C++ are all geared for full range dev across the entire spectrum. Ada due to external issues in tool and compiler availability is the more limited currently, but almost as broad. David Botton