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=unavailable autolearn_force=no version=3.4.4 X-Received: by 2002:a24:dbc5:: with SMTP id c188-v6mr5728688itg.37.1529368343837; Mon, 18 Jun 2018 17:32:23 -0700 (PDT) X-Received: by 2002:aca:c456:: with SMTP id u83-v6mr589611oif.4.1529368343768; Mon, 18 Jun 2018 17:32:23 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!feeder.erje.net!2.eu.feeder.erje.net!feeder.usenetexpress.com!feeder-in1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!d7-v6no5339824itj.0!news-out.google.com!z3-v6ni6697iti.0!nntp.google.com!u78-v6no5312076itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 18 Jun 2018 17:32:23 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=137.103.119.68; posting-account=ShYTIAoAAABytvcS76ZrG9GdaV-nXYKy NNTP-Posting-Host: 137.103.119.68 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <351c6acd-8a8c-41a3-bb52-dd3f82322829@googlegroups.com> Subject: Re: Comprehending subpools From: sbelmont700@gmail.com Injection-Date: Tue, 19 Jun 2018 00:32:23 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: reader02.eternal-september.org comp.lang.ada:53153 Date: 2018-06-18T17:32:23-07:00 List-Id: I guess it's just a case of me reading too much into things. The rationale= declares subpools "a major new facility", but I just couldn't (and perhaps= still can't) see a niche feature as being worth all the time and trouble. = When people say "far safer" i think of code that doesn't have to be prefix= ed with Unchecked_* at all, not just "you have to call it less". And sure, finalization is of course important, but subpools seem almost spe= cifically engineered to solve one problem that one person had writing one t= ype of program, and not a general-purpose building block (which happily mos= t features in Ada are). Which is fine for small features that are relative= ly easy, but just judging from the AI text, subpools seems to be the bigges= t change to 2012 second only to contracts, and it mostly seems, well, waste= d. It doesn't appear the default pool has to support them (?), so step one= to using a subpool is to go and implement a pool-with-subpools and hardcod= e your program to use it, and that's a high barrier to entry even when it's= warrented. And when there are so many other things developers on CLA are = always clamoring for (constructors), it all seems like an odd= way to focus energies. Not to be flippant, but my kingdom for a do loop..= .and 'do' is already a reserved word! I'd rather pull all the nonsense of wrapping access values in controlled ty= pes out of the client in the first place and put it into the pool itself (a= callback passed to allocate or something?), instead of just solving the pr= oblems piecemeal. Having to use controlled types for memory management is = the problem IMHO. Let code work with access values directly and leave it t= o the pool they came from to decide how and when to clean it up. I suppose i was just hoping for more. I would, however, be interested to h= ear examples of how other people have found them useful in their own code (= outside of compiler ASTs) to help foster my imagination of what else can be= done with them. Thank you again for the responses and continued support. -sb