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-Thread: a07f3367d7,1c5ea9562750d823 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII Path: g2news2.google.com!postnews.google.com!d2g2000pra.googlegroups.com!not-for-mail From: Adam Beneschan Newsgroups: comp.lang.ada Subject: Re: Ada extension information Date: Thu, 28 May 2009 15:06:08 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <4a1f0096$0$31331$9b4e6d93@newsspool4.arcor-online.net> NNTP-Posting-Host: 66.126.103.122 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1243548369 19808 127.0.0.1 (28 May 2009 22:06:09 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 28 May 2009 22:06:09 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: d2g2000pra.googlegroups.com; posting-host=66.126.103.122; posting-account=duW0ogkAAABjRdnxgLGXDfna0Gc6XqmQ User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; WOW64; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.21022; .NET CLR 3.5.30729; .NET CLR 3.0.30618),gzip(gfe),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:6090 Date: 2009-05-28T15:06:08-07:00 List-Id: On May 28, 2:22=A0pm, Georg Bauhaus wrote: > i...@midoan.com wrote: > > More specifically where are these Ada extensions formally documented? > > This is AI 147, Conditional Expressions (as primaries).http://www.ada-aut= h.org/cgi-bin/cvsweb.cgi/ai05s/ai05-0147-1.txt?rev=3D1.2 > > Yet another thing that makes Ada more attractive > for programmers who would not waste valuable time > for finding names, say write a small named function > that conditionally returs this or that. > Obviously, local functions are overly verbose > and explicative, they must be avoided at all cost. > > Ada finally gets C's =A0?: =A0conditionals! > Have you ever seen anyone using ?: in C or Perl in > a way that is obfuscating? Really? > > Nah, it's nice! =A0We can even leave out the bulky > comb structure. =A0Just pairs of parentheses! > the Lisp fans will rejoyce, C programmers will > feel at home, done with a single stroke! > > loop > =A0 =A0exit if (if N > 0 then M/N > 0 else M > 1); > =A0 =A0N :=3D F(M, N); > end loop; > > Not even Lisp or ML style let bindings are necessary! > Ah, fancy that! We've got more and more anonymous pointers, > free and easy, =A0why not free floating control structure > then? =A0I forget, it's a nice opportunity for tool vendors > to sell more style enforcment programs and language restriction > options. =A0They are learning ... :-) Hey, it's not part of the Ada language yet, so no need to get all worked up. This feature could still be rejected. And yes, this is certainly a feature that could be abused. But as the AI makes clear, there are cases where it can improve readability because there's no other good way to accomplish the same thing. Sure, there are programmers who don't understand readability who would use this construct in an inappropriate place, just because the feature is there. But those programmers probably wouldn't write readable code no matter how many features you took away from them. I've seen plenty of incomprehensible Ada 83 code so I'm sure this is true. -- Adam