From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Finalization of library level tasks
Date: Mon, 30 Apr 2018 15:03:40 +0200
Date: 2018-04-30T15:03:40+02:00 [thread overview]
Message-ID: <pc747c$1jle$1@gioia.aioe.org> (raw)
In-Reply-To: 3b736ddf-0807-4781-a973-6164280faae7@googlegroups.com
On 2018-04-30 14:27, AdaMagica wrote:
> Am Sonntag, 29. April 2018 21:36:37 UTC+2 schrieb Dmitry A. Kazakov:
>> On 2018-04-29 19:41, AdaMagica wrote:
>>> Am Samstag, 28. April 2018 10:35:34 UTC+2 schrieb Dmitry A. Kazakov:
>>>
>>>> All these instances *must* be finalized: X of T1 <- T2 <- T3 must be
>>>> finalized in the order
>>>>
>>>> Finalize (T1'Class (X));
>>>> Finalize (T2'Class (X));
>>>> Finalize (T3'Class (X));
>>> I don't have the slightest idea what should happen there.
>>
>> Anything necessary to finalize the class-wide object. E.g. informing a
>> task component to complete:
>
> What is this "anything"?
Anything the program logic requires for a class-wide finalization to be
done.
> I do not see a connection from class-wide type to its task components. What is the connection of class-wide type to other components? What's the difference between task components and other (perhaps limited) components? What does class-wide finalize do to those other components?
The reason why the object's type-specific finalization waits for all
component tasks to complete do not apply to class-wide finalization of
the same object.
When you have a task component with a Rosen's trick access discriminant
T1'Class in the object of T1, without waiting for the task, you may
finalize T3 and T2 and have the task running with a T1'Class object
partially finalized. This is why the task must complete *before*
finalization of T1, T2, T3 etc.
There is no problem not to wait for the task during finalization of
T1'Class because at this point T1, T2, T3 views of the object are all
intact. You can safely dispatch on the task discriminant to any target type.
From T1'Class finalization will shutdown the task and everything will
be fine, deadlock broken.
Similarly. Let the design require calling an abstract or overridden
operation upon finalization via dispatch. You cannot do that in the
Finalize of T1. The reason is exactly same as with the task completion:
the object is partially finalized in the type T3 where dispatch may lead
to. But you can safely dispatch in the Finalize of T1'Class, because T3
view is still there.
> In short: If you look inside a class-wide object, you'll find inside an object of a specific type within this class (as Randy said in a previous post). What's the property of this specific object seen as a class-wide object that's not a property of the specific object?
Simple. All properties of the class, overridden operations, in
particular. Primitive operations dispatch on a class-wide object, they
do not on a type-specific object.
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2018-04-30 13:03 UTC|newest]
Thread overview: 89+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-15 13:40 Finalization of library level tasks Dmitry A. Kazakov
2018-04-15 14:02 ` Jeffrey R. Carter
2018-04-15 14:12 ` Dmitry A. Kazakov
2018-04-15 14:54 ` Jeffrey R. Carter
2018-04-15 15:15 ` Dmitry A. Kazakov
2018-04-15 15:46 ` AdaMagica
2018-04-15 15:53 ` Dmitry A. Kazakov
2018-04-15 17:17 ` AdaMagica
2018-04-15 17:40 ` Dmitry A. Kazakov
2018-04-15 19:32 ` Egil H H
2018-04-15 20:09 ` Dmitry A. Kazakov
2018-04-25 23:49 ` Randy Brukardt
2018-04-16 5:19 ` J-P. Rosen
2018-04-16 7:30 ` Dmitry A. Kazakov
2018-04-16 7:55 ` J-P. Rosen
2018-04-16 8:13 ` Dmitry A. Kazakov
2018-04-16 8:32 ` J-P. Rosen
2018-04-16 15:26 ` Dmitry A. Kazakov
2018-04-17 9:51 ` AdaMagica
2018-04-17 12:31 ` Dmitry A. Kazakov
2018-04-17 15:37 ` Jeffrey R. Carter
2018-04-17 15:57 ` Dmitry A. Kazakov
2018-04-17 20:16 ` Jeffrey R. Carter
2018-04-17 20:59 ` Dmitry A. Kazakov
2018-04-18 5:20 ` J-P. Rosen
2018-04-17 20:55 ` J-P. Rosen
2018-04-17 21:23 ` Dmitry A. Kazakov
2018-04-18 5:26 ` J-P. Rosen
2018-04-26 0:02 ` Randy Brukardt
2018-04-18 8:06 ` AdaMagica
2018-04-18 8:25 ` Dmitry A. Kazakov
2018-04-18 8:52 ` Egil H H
2018-04-18 9:58 ` Dmitry A. Kazakov
2018-04-18 11:33 ` J-P. Rosen
2018-04-18 11:58 ` Dmitry A. Kazakov
2018-04-18 12:00 ` J-P. Rosen
2018-04-18 12:25 ` Dmitry A. Kazakov
2018-04-18 13:51 ` J-P. Rosen
2018-04-18 14:12 ` Dmitry A. Kazakov
2018-04-18 14:52 ` J-P. Rosen
2018-04-18 15:04 ` Dmitry A. Kazakov
2018-04-18 20:26 ` AdaMagica
2018-04-18 21:00 ` Dmitry A. Kazakov
2018-04-18 20:40 ` AdaMagica
2018-04-19 7:34 ` Simon Wright
2018-04-18 21:29 ` J-P. Rosen
2018-04-19 7:32 ` Dmitry A. Kazakov
2018-04-26 0:04 ` Randy Brukardt
2018-04-26 8:56 ` Dmitry A. Kazakov
2018-04-26 22:10 ` Randy Brukardt
2018-04-27 4:48 ` J-P. Rosen
2018-04-27 20:52 ` Randy Brukardt
2018-04-17 11:16 ` J-P. Rosen
2018-04-17 12:47 ` Dmitry A. Kazakov
2018-04-17 14:08 ` J-P. Rosen
2018-04-17 14:47 ` Dmitry A. Kazakov
2018-04-17 22:00 ` Robert A Duff
2018-04-18 7:25 ` Dmitry A. Kazakov
2018-04-25 23:54 ` Randy Brukardt
2018-04-26 16:22 ` Jeffrey R. Carter
2018-04-26 16:43 ` Dmitry A. Kazakov
2018-04-26 20:19 ` J-P. Rosen
2018-04-16 9:19 ` AdaMagica
2018-04-16 15:15 ` Dmitry A. Kazakov
2018-04-19 20:39 ` G. B.
2018-04-20 7:27 ` Dmitry A. Kazakov
2018-04-25 23:46 ` Randy Brukardt
2018-04-26 9:03 ` Dmitry A. Kazakov
2018-04-26 22:25 ` Randy Brukardt
2018-04-27 7:37 ` Dmitry A. Kazakov
2018-04-27 8:32 ` AdaMagica
2018-04-27 8:57 ` Dmitry A. Kazakov
2018-04-27 21:08 ` Randy Brukardt
2018-04-28 8:35 ` Dmitry A. Kazakov
2018-04-29 17:41 ` AdaMagica
2018-04-29 19:36 ` Dmitry A. Kazakov
2018-04-30 12:27 ` AdaMagica
2018-04-30 13:03 ` Dmitry A. Kazakov [this message]
2018-04-30 16:52 ` Jeffrey R. Carter
2018-04-30 17:06 ` Dmitry A. Kazakov
2018-05-01 9:17 ` AdaMagica
2018-05-01 9:40 ` Dmitry A. Kazakov
2018-05-01 11:18 ` Jeffrey R. Carter
2018-05-01 11:27 ` Dmitry A. Kazakov
2018-05-01 15:54 ` Niklas Holsti
2018-05-02 14:34 ` AdaMagica
2018-05-02 14:50 ` Dmitry A. Kazakov
2018-05-01 2:27 ` Randy Brukardt
2018-05-01 6:59 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox