Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!linus!philabs!cmcl2!seismo!think!nike!cad!ucbvax!oslo.uio.edu!sigurd From: sigurd@oslo.uio.edu (Sigurd Meldal) Newsgroups: net.lang.ada Subject: Re: Propagation of exceptions raised in tasks Message-ID: <518775761.sigurd@oslo-vax> Date: Tue, 10-Jun-86 13:22:00 EDT Article-I.D.: oslo-vax.518775761.sigurd Posted: Tue Jun 10 13:22:00 1986 Date-Received: Fri, 13-Jun-86 02:20:20 EDT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 30 Ben Brosgol writes > The problems with asynchronous exceptions are why exceptions do not propagate > out of tasks. That is, there is no way of knowing where the parent task > is when the child task raises the exception. Asynchronous exception raising > would be an unreliable and hard to implement means of synchronization. So, > sorry about the lack of symmetry between tasks and other units with > respect to exception propagation, but tasks are different in an essential way > here. However, there is at least one well-defined point to which an exception raised in a task could be propagated. Since a block statement, task etc. which has dependent tasks is not terminated unless all dependent tasks are completed, we have a synchronization point at the end of this master (LRM 9.4). One might lay down the rule that an exception propagated out of a task is handled by a handler of the direct master of the task raising the exception, in effect interrupting the master. One would probably have to insist that the propagation of an exception out of a task kills all tasks dependent on the master handling the exception, a rather heavy-handed treatment if synchronization is the issue, but reasonable if exceptions really are exceptional and are treated as such. Sigurd Meldal Hard mail: Institute of Informatics | ARPA: sigurd@oslo-vax.arpa University of Oslo | pob. 1080 Blindern | N - 0316 Oslo 3 | Norway. |