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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,f822ae7b0f7433c1 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!m58g2000cwm.googlegroups.com!not-for-mail From: "Steve Whalen" Newsgroups: comp.lang.ada Subject: Re: Translating an embedded C algorithm Date: 18 Jan 2007 18:11:13 -0800 Organization: http://groups.google.com Message-ID: <1169172673.116628.130060@m58g2000cwm.googlegroups.com> References: <1168871816.263502.212100@11g2000cwr.googlegroups.com> <45acc0c3$0$22514$39db0f71@news.song.fi> <45af9c60$0$22524$39db0f71@news.song.fi> NNTP-Posting-Host: 69.41.132.226 Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Trace: posting.google.com 1169172678 29234 127.0.0.1 (19 Jan 2007 02:11:18 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 19 Jan 2007 02:11:18 +0000 (UTC) User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.9) Gecko/20061206 Firefox/1.5.0.9,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: m58g2000cwm.googlegroups.com; posting-host=69.41.132.226; posting-account=GBMmzA0AAABrZ0dHOASa3b2Cdf-RliH9 Xref: g2news2.google.com comp.lang.ada:8299 Date: 2007-01-18T18:11:13-08:00 List-Id: Niklas Holsti wrote: > ... I think that an Ada translation of this C function can, with a bit of > elaboration, illustrate several Ada features for "programming in the > small", even if not for "programming in the large". > > So here is my try at an Ada version of the code and some of the context. ... Thank you for taking the time to create the Ada version of the example. I agree with the others that it is very well done. Even if your example were not as well done as it is, almost any correct Ada example would have been vastly better than a blank page in a book. Especially in a book targeted at a field where Ada should be considered more frequently than it is. If you hadn't created this example, the author also would have been quite justified in putting a comment in the book that the programmers on comp.lang.ada think Ada is not well suited to embedded programming (or at least that it would be too much work to create an illustrative Ada example). Thanks again for taking the time to write the Ada code. Maybe Martin can find a place for it in his Wiki book on Ada programming. Also, you might want to send a copy of the code to the OP, since I'm not sure the OP is still reading this thread, given the relatively unprofessional reception the OP was given here. Steve