"J-P. Rosen" wrote in message news:pb6kuf$jgl$1@gioia.aioe.org... > Le 17/04/2018 à 23:23, Dmitry A. Kazakov a écrit : >> P.S. If "main subprogram complete" should mean "environment task >> complete" that is OK to me. However insane the wording sounds to me only >> the semantics counts. > The paragraph you quote says "has completed", not "complete". Remember, > the main subprogram is called by the environment task. So, the main > subprogram completes and exits, then the environment task waits for > dependents, at which point its 'callable becomes false. > >> Why could not "task complete" mean "will select >> next terminate"? At least it would make some use out of having >> T'Callable. > 'Callable is very useful for regular tasks. Your quote suggests that > there might also be some use for it on the environment task, which is > not obvious. I invented that to get around Dmitry's original problem when I stumbled into it building Claw right after Ada 95 was finished. I was able to convince the ARG that the environment task ought to be completed once the main subprogram exits [that follows from the definition of the environment task], and that one should be able to use Ada.Task_Identification to query that. (You could do it even before the Environment_Task function, you just had to squirrel the environment task id during initial elaboration.) Several compilers didn't do this right, but one of the first things I added to the ACATS after taking over was a test of this case (once the ARG approved the idea, of course). So all modern compilers support the idiom of testing Callable of the environment task. Randy.