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 Path: buffer2.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news.snarked.org!feeder.erje.net!eu.feeder.erje.net!news2.arglkargh.de!news.albasani.net!news.stack.nl!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: newbie: can't read fast enough... :-) memory leaks... Date: Wed, 3 Sep 2014 21:29:18 +0200 Organization: cbb software GmbH Message-ID: <1k0faltm0llur.1oxkha2ciurb2$.dlg@40tude.net> References: <479b2efe-0238-4b2a-8b05-cb1a0b4a57e5@googlegroups.com> <1409739464.7121.235.camel@obry.net> <1409765762.11813.2.camel@obry.net> <7fc51817-16c9-4955-91a1-d97cde61a15b@googlegroups.com> <15508226-3892-41b3-8c82-5f44eca527b5@googlegroups.com> Reply-To: mailbox@dmitry-kazakov.de NNTP-Posting-Host: etnUhctbDQ6U1zAlbX4CBw.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org User-Agent: 40tude_Dialog/2.0.15.1 X-Notice: Filtered by postfilter v. 0.8.2 Xref: number.nntp.dca.giganews.com comp.lang.ada:188844 Date: 2014-09-03T21:29:18+02:00 List-Id: On Wed, 3 Sep 2014 12:19:00 -0700 (PDT), gdotone@gmail.com wrote: > is this why a garbage collector is not part of the language? well part of > the standard? or because of syntax and semantics of the language leaks are > rare? I would say because the cure is worse than the disease. But this is my opinion... In particular, finalization under a collector is performed with no regard to interdependencies of the collected objects. The property of being "unreachable" is not enough to determine the correct order of finalization. If some order is established using references, then the gates of hell opens, hard references, weak references, cyclic references etc. And should you have references already, a reference counting schema would be as good as automated collection. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de