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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,82c66e12b62744fb X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2000-10-03 20:23:08 PST Path: supernews.google.com!sn-xit-02!supernews.com!isdnet!209.249.123.233.MISMATCH!xfer10.netnews.com!netnews.com!news-xfer.newsread.com!bad-news.newsread.com!netaxs.com!newsread.com!POSTED.monger.newsread.com!not-for-mail Message-ID: <3A0230E5.E666B9B8@telepath.com> From: Ted Dennison X-Mailer: Mozilla 4.72 [en] (Windows NT 5.0; I) X-Accept-Language: en,pdf MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Memory leakage References: <39D8CD62.7B6EB2D4@boeing.com> <8rapg8$66b$1@nnrp1.deja.com> <8re4ba$tvs$1@nnrp1.deja.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Wed, 04 Oct 2000 00:40:26 GMT NNTP-Posting-Host: 38.195.186.125 X-Complaints-To: Abuse Role , We Care X-Trace: monger.newsread.com 970620026 38.195.186.125 (Tue, 03 Oct 2000 20:40:26 EDT) NNTP-Posting-Date: Tue, 03 Oct 2000 20:40:26 EDT Organization: Telepath Systems (telepath.com) Xref: supernews.google.com comp.lang.ada:972 Date: 2000-10-04T00:40:26+00:00 List-Id: Robert Dewar wrote: > In article <8rapg8$66b$1@nnrp1.deja.com>, > Ted Dennison wrote: > > > You suspect correctly. It is quite easy to produce memory > leaks in Ada, > > if you really want to. All you have to do is use "new", and > not ever > > use Unchecked_Deallocation. > > That missed the point of the question, it is not a memory > leak in language terms to allocate and never free using > appropriate statements in the language, this is simply > doing what you are asked to, and the only thing that makes > it a leak is intent. You cut the original question, which to me is quite clear that it is talking about the possibility of having memory leaks in an Ada95 program. Here it is again: > My impression is that in Ada 95 it should not be possible to have memory leaks, but I'm not so sure. The source (user mistakes vs. language problems) was not mentioned. Therefore both should be assumed to be under discussion. Perhaps I did misread the poster's intent as you suggest, but its certainly not clear that I did! I know it sounds like a silly question to a lot of experts. But I have encountered lots of folks before who have heard this sillyness about Ada; that its somehow immune to memory leaks. I've also heard the opposite fantasy: that it somehow leaks memory just by existing on your hard-drive. If someone comes here questioning one of these views, we should certainly be ready to address it, no matter how silly of an idea it is. Not that what you are talking about is a invalid realm of discussion either. But if you would *prefer* to talk about that, just come out and say so. We won't hold it against you. :-) > The question was whether using constructs in the language > you can get leaks, and the answer should be no. I do seem to remember an issue with tasks having to keep data about themselves around after they terminate (perhaps for the 'terminated attribute?). -- T.E.D. Home - mailto:dennison@telepath.com Work - mailto:dennison@ssd.fsi.com WWW - http://www.telepath.com/dennison/Ted/TED.html ICQ - 10545591