comp.lang.ada
 help / color / mirror / Atom feed
From: mcsun!corton!enst!cyclope!rosen@uunet.uu.net  (Jean Pierre Rosen)
Subject: Re: Task Access Type Variables
Date: 19 Jul 91 14:30:27 GMT	[thread overview]
Message-ID: <166@cyclope.enst.fr> (raw)

In article <9107181212.aa26405@PARIS.ICS.UCI.EDU>, jduarte@liege.ICS.UCI.EDU (J
 o s e D u a r t e) writes:
> 
> Here's a question:
> 
> 	What happens to the value of a variable which
> is an access to a task (type) once the task completes
> its job or terminates for some reason?
> ...
Since the LRM says nothing special, the answer is plain: nothing special
happens!
You can use it to ask for the status of the task (T'terminated will be true)
or even call entries (which will raise TASKING_ERROR, of course).
If you UNCHECK_DEALLOCATE it, you might deallocate the task's descriptor space
(not sure any compiler does it). Don't be confused with the reverse statement:
if you deallocate a pointer to task before it is terminated, the task is
NOT affected.

This may be the place for an interesting remark about access variables in
general. A plain variable is a name that designates always the same object.
It is a kind of "constant" variable. An access variable is simply a name that
can designate different objects over time, a kind of "variable" variable.
Both behave basically the same. That's why you can write T(I), whether T is
an array or an access to an array.

An Ada access is by no mean an address!! 

             reply	other threads:[~1991-07-19 14:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1991-07-19 14:30 Jean Pierre Rosen [this message]
  -- strict thread matches above, loose matches on Subject: below --
1991-07-20  0:38 Task Access Type Variables Robert I. Eachus
1991-07-19 13:22 Norman H. Cohen
1991-07-18 21:03 J o s e D u a r t e
1991-07-18 19:12 J o s e D u a r t e
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox