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=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,d8a4797a79f9c90f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-05-26 18:35:43 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!in.100proofnews.com!in.100proofnews.com!cycny02.gnilink.net!cyclone1.gnilink.net!spamkiller2.gnilink.net!nwrdny03.gnilink.net.POSTED!53ab2750!not-for-mail From: Hyman Rosen User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4b) Gecko/20030524 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: I/O - exception handling References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Tue, 27 May 2003 01:35:43 GMT NNTP-Posting-Host: 162.84.146.112 X-Complaints-To: abuse@verizon.net X-Trace: nwrdny03.gnilink.net 1053999343 162.84.146.112 (Mon, 26 May 2003 21:35:43 EDT) NNTP-Posting-Date: Mon, 26 May 2003 21:35:43 EDT Xref: archiver1.google.com comp.lang.ada:37817 Date: 2003-05-27T01:35:43+00:00 List-Id: Sergey Koshcheyev wrote: > I myself miss constructors and destructors in Ada a lot. Well, Ada has them, albeit in an inconvenient form. You need a type which inherits from Controlled, and that type must be declared at library level for some safety reason that Ada folks appreciate. I don't know if there's a way to use access discriminants in combination with generics to get a "universal" cleanup object that could forward to a function. Ada experts?