From: mheaney@ni.net (Matthew Heaney)
Subject: Re: idiom for task termination?
Date: 1997/02/10
Date: 1997-02-10T00:00:00+00:00 [thread overview]
Message-ID: <mheaney-ya023680001002972039190001@news.ni.net> (raw)
In-Reply-To: 32FF32D7.67D2@elca-matrix.ch
In article <32FF32D7.67D2@elca-matrix.ch>, Mats.Weber@elca-matrix.ch wrote:
>The user of P will then delcare an object of type P.ADT, which will make
>him the master of the task object, and the terminate alternative in the
>body of ADT will be selected when the program terminates.
But the question is, Does the select even have a terminate alternative? If
you need to do some work before you terminate - such as shut down a device
or close a file - then you have to be told explicity to shut down.
You are correct that a terminate alternative would do the trick, but only
if the server task doesn't have to do anything before terminating. That's
why I asked if the abstraction required to be told to quit.
Asking, How do I quit if my client forgets to tell me to quit?, is a little
like asking, What happens if I use Unchecked_Conversion to return a value
outside the range of the target type? Of course, the behaviour is
undefined, so don't do it.
matt
--------------------------------------------------------------------
Matthew Heaney
Software Development Consultant
<mailto:matthew_heaney@acm.org>
(818) 985-1271
next prev parent reply other threads:[~1997-02-10 0:00 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <32FA10EF.32A@bix.com>
1997-02-07 0:00 ` idiom for task termination? Robert A Duff
1997-02-07 0:00 ` Mats Weber
1997-02-18 0:00 ` Robert A Duff
1997-02-07 0:00 ` Tom Moran
1997-02-08 0:00 ` Matthew Heaney
1997-02-09 0:00 ` Tom Moran
1997-02-10 0:00 ` Matthew Heaney
1997-02-10 0:00 ` Mats Weber
1997-02-10 0:00 ` Matthew Heaney [this message]
1997-02-11 0:00 ` Tom Moran
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox