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, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,75c440b4b7ed5f91 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!wn11feed!worldnet.att.net!bgtnsc04-news.ops.worldnet.att.net.POSTED!53ab2750!not-for-mail Newsgroups: comp.lang.ada From: anon@anon.org (anon) Subject: Re: Real Time IO routines answering Simon Wright part 2 Reply-To: anon@anon.org (anon) References: <1193410739.367181.96050@50g2000hsm.googlegroups.com> <1193844955.601875.108200@e34g2000pro.googlegroups.com> X-Newsreader: IBM NewsReader/2 2.0 Message-ID: Date: Wed, 31 Oct 2007 20:08:14 GMT NNTP-Posting-Host: 12.65.204.69 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc04-news.ops.worldnet.att.net 1193861294 12.65.204.69 (Wed, 31 Oct 2007 20:08:14 GMT) NNTP-Posting-Date: Wed, 31 Oct 2007 20:08:14 GMT Organization: AT&T Worldnet Xref: g2news2.google.com comp.lang.ada:2684 Date: 2007-10-31T20:08:14+00:00 List-Id: In 1990's, NYU/Adacore and others suggested this at a conference and the Ada committee voted this and a few other standards for the Ravenscar profile. And a few vendors even coded this into their Ravenscar profile for their compilers. (GNAT 3.00 had it embeded in the compiler) >From the information of the Ada committee, this was also suggested that it become apart of the next specification amendment to Ada. That would have been in the updated Ada 95 standard "ISO/IEC 8652:1995(E) with Corrigendum 1 and Amendment 1" back in 2001. What happen well I think it was the DOD and 1998 that killed the idea. Europe was one who do not like some of the Ada committee new standards, so when the US government pulled out, so did those standards including the new coding practices. Just like some follow the "Ada coding style guide", some do not. The only one that GNAT follows to letter is the spacing, which makes some of the code hard to read. But the rule on limiting comments, well just look at some of GNAT specifications. If you say that they followed that rule well than I will be the next Pres of the US. Since the style in not enforce in the compiler like others languages then why follow them. For GNAT it is enforce by options by the programmer not the Specifications. But I and some others like to be able to read the code and understand what the programmer is doing and spacing with a lot of comments allow that. Plus, most programmer start out by believing the "Core Algorithm" is the most important part of a partition. But as any published programmer will tell you that "Documentation" is number one, followed by the "User Interface" and the last item is the "Core Algorithm". A published programmer will also tell any programmer that the "User Interface" should take about 75% of the coding time while the "Core Algorithm" should take less than 5%. And even though Ada has no real GUI in the specification it does have some. Rather the data is printed to the monitor or to a printer, the user (or teacher in the case of students) wants to be able to read the results without eye stain and in a timely fashion, that is, only the valid significant data. Which means that a programmer has to formatted their outputted data in a fashion that is informative but not too much that it causes confusion or stain in the user. And any 19 year programming vet. should knows this!!! And to allow a student to believe differently is just wrong. Unformatted output and bad programming practices should never be allowed in code, except as a teaching tool, with documentation that states this. Even if the statement is legal, those techniques and statements are for DEBUGGING ONLY. No one else should see unformatted data except for the programmer, while testing his "Core Algorithm". Leaving you with the idea. Which would you per to look at or read for 8 hours a day: This " 11938588250.273822028" or this "250.273" for relative information. Or would you like the TAX man to see that you have: 588200.797647034 and reads it as 588288.88 because of eye stain or reads it as 588_200.79 or even 588,200.79 which is correct. Note: .88 is the number is rounded to .80 and the 88s because of eye stain. After a while '0' can look like '8'. And in both cases the unformatted output will get the programmer fired. In <1193844955.601875.108200@e34g2000pro.googlegroups.com>, Adam Beneschan writes: >On Oct 30, 9:35 am, a...@anon.org (anon) wrote: > >> -- Where did I get the information that IMAGE should be use for >> -- debugging only? A few Ada conferences back in the early to >> -- mid 1990's dealing with Ada programming and debugging >> -- techniques. > >To be precise, that should be called "opinion", not "information". >OK, so I wasn't at the conferences you mention, so I really don't know >how this "information" was presented or what the context was. There >may have been reasons for discouraging its use---the secondary stack >may be one reason; another possible reason is that less-experienced >programmers were prone to misuse 'Image. Or it could have been due to >efficiency concerns with passing unconstrained arrays around. Or it >could have just been someone's personal idea about what Ada was >"supposed" to be. Of course, there is no shortage of people who have >difficulty distinguishing their own opinions from factual >information. > >If the "information" was that there was a consensus in the Ada >community that 'Image was to be avoided, maybe that was true---I don't >know---but on the other hand, I suspect that if it were true then >'Image wouldn't have been expanded. In Ada 83, you could not use >'Image on floating or fixed-point types; in Ada 95, this capability >was added. It would seem a little odd for those who decided on what >would be added to Ada 95---who are about as far from "newbie" as you >can get---to add this feature if there was a consensus that 'Image was >a bad thing. Also, the responses on this thread (from people with a >lot of Ada experience) seem to indicate that there is no such >consensus. > >Anyway, I can imagine that 'Image may be misused sometimes, and that >some people felt it should be discouraged. But it's a big jump to go >from there to the absolute statements you made that Ada purists >"NEVER" use it, or that it is never used except for debugging, or that >practically only newbies use it. Those statements are still nonsense. > > -- Adam > >