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=unavailable autolearn_force=no version=3.4.4 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!aioe.org!.POSTED!not-for-mail From: Victor Porton Newsgroups: comp.lang.ada Subject: Aborting a recursive subprogram by an exception Date: Thu, 28 Aug 2014 22:26:55 +0300 Organization: Aioe.org NNTP Server Message-ID: NNTP-Posting-Host: AnnUDmZwVERVUXyHDyOl5A.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: abuse@aioe.org User-Agent: KNode/4.13.3 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:21960 Date: 2014-08-28T22:26:55+03:00 List-Id: See also http://stackoverflow.com/questions/25556441/aborting-a-recursive-subprogram-in-the-middle If I want to abort a recursive subprogram in the middle, is throwing an exception from it a good way to do this? I am not sure whether exception optimizations allowed by Ada RM may not nullify some external actions of the subprogram (such as modifying global variables) which are before throwing the exception. Will it work with exceptions the right way? -- Victor Porton - http://portonvictor.org