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 10.236.63.67 with SMTP id z43mr17887390yhc.11.1407865870137; Tue, 12 Aug 2014 10:51:10 -0700 (PDT) X-Received: by 10.140.36.66 with SMTP id o60mr29120qgo.28.1407865870120; Tue, 12 Aug 2014 10:51:10 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!au2pb.net!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!peer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!v10no6527869qac.1!news-out.google.com!j6ni43193qas.0!nntp.google.com!v10no6527863qac.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 12 Aug 2014 10:51:10 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=73.179.102.101; posting-account=wEPvUgoAAABrLeiz_LRhQ3jeEhyfWVMH NNTP-Posting-Host: 73.179.102.101 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: A simple question about the "new" allocator From: NiGHTS Injection-Date: Tue, 12 Aug 2014 17:51:10 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Received-Bytes: 2036 X-Received-Body-CRC: 3702904955 Xref: news.eternal-september.org comp.lang.ada:21687 Date: 2014-08-12T10:51:10-07:00 List-Id: Thank you all for your help with this problem. After spending some time thi= nking about this issue and with what you all of you have prescribed as ways= to avoid crashing the program, I think my approach will be to use access o= nly on aliased variables that were instantiated using other devices that do= not require the use of "new" directly. G.B.'s storage pool approach intrigues me and I will be sure to study this = code to help me understand how I can apply storage pools to various complex= situations which are sure to come up. Though today I think I found good wa= ys of avoiding "new" in the context described in my first message. When instantiating new memory in a define block, when does the compiler use= the stack memory and when does it use the heap? I worry that trying to avo= id "new" will cause the stack memory to be out of control.