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-Thread: 103376,9fb8e2af320d5b3e X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!198.186.194.247.MISMATCH!news-out.readnews.com!news-xxxfer.readnews.com!panix!newsfeed-00.mathworks.com!nntp.TheWorld.com!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Bus error Date: Thu, 28 Jun 2007 17:19:09 -0400 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <1182954233.788124.17920@c77g2000hse.googlegroups.com> <1182959120.13096.8.camel@kartoffel> <1182964748.689146.52490@c77g2000hse.googlegroups.com> <1183061209.600996.74710@k79g2000hse.googlegroups.com> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: pcls6.std.com 1183065550 21167 192.74.137.71 (28 Jun 2007 21:19:10 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Thu, 28 Jun 2007 21:19:10 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:NEpEN2b6KVscGEd8kamgyUUEeho= Xref: g2news1.google.com comp.lang.ada:16332 Date: 2007-06-28T17:19:09-04:00 List-Id: Maciej Sobczak writes: > On 28 Cze, 03:58, Robert A Duff wrote: > >> > BTW - is it necessary to reveal in the public view that the type is >> > tagged? >> >> No. You can have an untagged private type whose full type is tagged. > > You mean - untagged *public*, I suppose? Yeah, the terminology is confusing. I mean: package P is type T is limited private; private type T is tagged limited ...; end P; or: with Ada.Finalization; use Ada; package P is type T is limited private; private type T is new Finalization.Limited_Controlled with ...; end P; Both of the above are legal. >> > I cannot check it, because this time I get the explicit "GNAT BUG >> > DETECTED". >> >> ...which requests that you send a bug report. > > I conclude that AdaCore guys read comp.lang.ada as well. :-) Not really. ;-) I read it once in a while, but often not for months at a time. Most AdaCore folks do not read comp.lang.ada at all. And AdaCore certainly does not go looking for GNAT bugs on comp.lang.ada. If you want a bug fixed, you have to send an official bug report. And if you want it fixed fast, or want AdaCore to answer your questions, you have to spend money. >> As to your original question, about an extension aggregate: I don't see >> anything wrong with your code, and I do recall fixing a bug in that area >> (extension aggregate of limited type with controlled parts returned from >> build-in-place function) a month or so ago. The bug fix will eventually >> find its way into the public version of GNAT. > > That's a good news, really. I consider this feature (limited > controlled with unknown discriminant) to be fundamental for correct > handling of external resources and other "interesting" types. It is > really a high time for this feature to get a wider adoption. Right, but it's the Ada 2005 build-in-place function return stuff that makes these really useful. The bug we're talking about (assuming it really is the same bug that I fixed, which I can't promise) was a nasty interaction between build-in-place functions and controlled types. - Bob