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=unavailable autolearn_force=no version=3.4.4 X-Received: by 2002:a24:1a57:: with SMTP id 84-v6mr3730324iti.36.1526658513672; Fri, 18 May 2018 08:48:33 -0700 (PDT) X-Received: by 2002:aca:d415:: with SMTP id l21-v6mr47258oig.1.1526658513571; Fri, 18 May 2018 08:48:33 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.uzoreto.com!weretis.net!feeder6.news.weretis.net!feeder.usenetexpress.com!feeder-in1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!u74-v6no1690945itb.0!news-out.google.com!f20-v6ni1931itd.0!nntp.google.com!u74-v6no1690944itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 18 May 2018 08:48:33 -0700 (PDT) In-Reply-To: <9620309c-8abc-4ff2-b631-73bbc72ee5d4@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=131.95.120.109; posting-account=JSxOkAoAAADa00TJoz2WZ_46XrZCdXeS NNTP-Posting-Host: 131.95.120.109 References: <6420bab2-0aef-4d36-b978-525e4de45e7e@googlegroups.com> <1559505943.548291689.457576.laguest-archeia.com@nntp.aioe.org> <87fu2psqpj.fsf@nightsong.com> <300fd624-72a0-4171-90dc-49ad5df4fa21@googlegroups.com> <877eo1shlv.fsf@nightsong.com> <9620309c-8abc-4ff2-b631-73bbc72ee5d4@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <12f81e06-6fb0-49c9-9c6a-ed2615e96d32@googlegroups.com> Subject: Re: meaningfully/compellingly "advertising" Ada on StackOverflow From: John Perry Injection-Date: Fri, 18 May 2018 15:48:33 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: reader02.eternal-september.org comp.lang.ada:52436 Date: 2018-05-18T08:48:33-07:00 List-Id: On Friday, May 18, 2018 at 10:39:14 AM UTC-5, John Perry wrote: > On Thursday, May 17, 2018 at 11:38:53 PM UTC-5, Paul Rubin wrote: > > John Perry writes: > > > I'm curious: did my implementation circumvent safety features? > >=20 > > Were there any unchecked array accesses or anything like that? If not, > > that's a big help. >=20 > No arrays at all; it's just linked lists. It's dangerous inasmuch as poin= ters are dangerous, but I know from experience that Ada has certain rules t= o prevent pointer dangling. I want to update on this. I can see two places where I might have circumven= ted safety features (besides using pointers/access types). 1) There are unchecked deallocations. This is one thing where I'm not too c= lear on: should one be doing this? The impression I had from what I've seen= in Barnes' book is that one should not; apparently Ada is supposed to take= care of this by itself, although it doesn't "garbage collect," either. I d= on't quite understand this -- does it have to do with the custom memory poo= ls? 2) The instruction have the -gnatp option, which I think disables some chec= ks. I used that at one point to see if it would speed up the code, and I th= ought it did, but I think it actually didn't in the end. So that could be r= emoved; I actually tried experimenting with various pragmas to improve timi= ng, without success.