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: 103376,93a8020cc980d113 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!news3.google.com!proxad.net!proxad.net!oleane.net!oleane!hunter.axlog.fr!nobody From: Jean-Pierre Rosen Newsgroups: comp.lang.ada Subject: Re: What is wrong with Ada? Date: Mon, 16 Apr 2007 10:50:49 +0200 Organization: Adalog Message-ID: References: <1176150704.130880.248080@l77g2000hsb.googlegroups.com> <461B52A6.20102@obry.net> <461BA892.3090002@obry.net> <82dgve.spf.ln@hunter.axlog.fr> <1176226291.589741.257600@q75g2000hsh.googlegroups.com> <4eaive.6p9.ln@hunter.axlog.fr> <1176578930.062156.49570@b75g2000hsg.googlegroups.com> NNTP-Posting-Host: mailhost.axlog.fr Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Trace: s1.news.oleane.net 1176714066 31724 195.25.228.57 (16 Apr 2007 09:01:06 GMT) X-Complaints-To: abuse@oleane.net NNTP-Posting-Date: Mon, 16 Apr 2007 09:01:06 +0000 (UTC) User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) In-Reply-To: <1176578930.062156.49570@b75g2000hsg.googlegroups.com> Xref: g2news1.google.com comp.lang.ada:15055 Date: 2007-04-16T10:50:49+02:00 List-Id: Chad R. Meiners a �crit : >> Trace messages are put just to check an hypothesis, and removed >> immediately afterwards. Certainly not kept in configuration, and limited >> to a couple of lines! > > I always keep important hypothesis (trace statements) around during > development because a particular trace sequence for a particular bug > does not ensure full coverage of the the algorithm. I have needed the > same trace statement more than once at different times in some > software life cycles. Aren't you confusing traces with assertions? I certainly leave assertions in my programs (and they call a "failure" procedure if they fail, with useful information). But I remove traces as soon I know what I was looking for. >>> and it is much easier to trace through >>> the algorithm step by step (using conditional breaks when necessary). >> My experience is that recompiling (generally a single body where you >> added the trace) is much faster than starting the debugger, setting >> breakpoints, skipping lots of unnecessary breaks, and so on. > > And my experience is that starting a debugger is faster than inserting > some verbose trace statements, and then recompiling. If you are > skipping a lot of unnecessary breaks, you are not using the debugger > properly. OK, take a typical example (of what I am doing, YMMV). In an ASIS program (AdaControl of course), I have a failure due to an "inappropriate element" to a given call, that I can easily identify from the stack trace. That place is called very often, just once in a while is the parameter incorrect. With a trace, I just have to read the last message befor the failure. But since I don't know beforehand how many times the sequence is called before failing, I would have to break on any occurrence - maybe hundreds. Not counting the fact that it is after I type "continue" that the program fails, and that I know that I just restarted from the point where I should have been investigating! -- --------------------------------------------------------- J-P. Rosen (rosen@adalog.fr) Visit Adalog's web site at http://www.adalog.fr