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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,e0c2a51d337d44ce X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!24g2000yqm.googlegroups.com!not-for-mail From: Maciej Sobczak Newsgroups: comp.lang.ada Subject: Re: exit a program Date: Mon, 3 Aug 2009 01:17:25 -0700 (PDT) Organization: http://groups.google.com Message-ID: <7737506d-395c-441e-ab21-78cb2f7b2bfb@24g2000yqm.googlegroups.com> References: NNTP-Posting-Host: 137.138.182.236 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: posting.google.com 1249287445 8915 127.0.0.1 (3 Aug 2009 08:17:25 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Mon, 3 Aug 2009 08:17:25 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: 24g2000yqm.googlegroups.com; posting-host=137.138.182.236; posting-account=bMuEOQoAAACUUr_ghL3RBIi5neBZ5w_S User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.0.12) Gecko/2009070609 Firefox/3.0.12,gzip(gfe),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:7535 Date: 2009-08-03T01:17:25-07:00 List-Id: On 2 Sie, 14:43, "Dmitry A. Kazakov" wrote: > > is there an instruction that stops a program? > > No, because it is ill-defined. > > In order to define "stop of a program" consider what happens with the > system resources allocated by the program (open files, shared libraries, > sockets etc) Shared libraries and sockets are out of Ada scope. If you are using them, then you apparently already know what you are doing. Files are in the scope and are handled (A.7/6): "The language does not define what happens to external files after the completion of the main program and all the library tasks" I guess it is up to the implementation to fill this gap. In other words, the concept of stopping the program is not ill- defined... > > i need to stop a program and return to o.s. in case of an exception. > > Let it propagate out of the main task, that will terminate the program. and you even give instructions on how it can be done. ;-) -- Maciej Sobczak * www.msobczak.com * www.inspirel.com Database Access Library for Ada: www.inspirel.com/soci-ada