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,ee06257af909a235,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Date: Tue, 08 May 2007 23:55:08 +0200 From: Manuel Collado User-Agent: Thunderbird 1.5.0.7 (Windows/20060909) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Finalization of static package variables Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 138.100.242.202 Message-ID: <4640f20b$1@news.upm.es> X-Trace: news.upm.es 1178661387 138.100.242.202 (8 May 2007 23:56:27 +0200) Path: g2news1.google.com!news4.google.com!news.germany.com!ecngs!feeder.ecngs.de!130.59.10.21.MISMATCH!kanaga.switch.ch!switch.ch!news.rediris.es!news.upm.es!not-for-mail Xref: g2news1.google.com comp.lang.ada:15665 Date: 2007-05-08T23:55:08+02:00 List-Id: Variables declared in the global scope of a package body seem not to be finalized automatically at the end of the whole program (using GNAT 3.15p on WindowsXP). If some of these variables contain certain GUI stuff, the program remains as a zombie process after the main procedure termination. After several trial-and-error attemps, an Unchecked_Deallocation on these variables seems to do the trick (the whole program terminates smoothly). But this is probably not standard-conformant (ARM 13.11.2-16). If there a standard way of forcing finalization of static package variables at program termination? I.e., without declaring them as dynamic, or inside a main procedure, or calling explicitly the finalization actions. Thanks in advance. -- Manuel Collado - http://lml.ls.fi.upm.es/~mcollado