Re: Abnormal objects - how they can become normal again?
- From: Robert A Duff <bobduff@xxxxxxxxxxxxxxxxxxxx>
- Date: 22 Dec 2005 10:57:36 -0500
"Alex R. Mosteo" <devnull@xxxxxxxxxxxxxx> writes:
> Robert A Duff wrote:
> > (snip)
> > Another way to deal with abnormal (possibly controlled) objects is to
> > add a level of indirection. I believe you can Unchecked_Deallocate an
> > abnormal object (not sure). Assignment of access values does not
> > involve finalization. So when you have a possibly-abnormal object, you
> > could simply throw it away and create a new one.
>
> I guess you can indeed free abnormal controlled objects, but this will
> trigger finalization, and I think the OP wanted to avoid this (as this
> happens too when overwriting the abnormal object during asignation).
Good point.
So I guess the answer is, "never allow controlled objects to become
abnormal (if you wish to use them ever again)". And as I said, abort
deferral can help you program this. It's not easy.
- Bob
.
- References:
- Abnormal objects - how they can become normal again?
- From: Maciej Sobczak
- Re: Abnormal objects - how they can become normal again?
- From: Robert A Duff
- Re: Abnormal objects - how they can become normal again?
- From: Alex R. Mosteo
- Abnormal objects - how they can become normal again?
- Prev by Date: Re: Abnormal objects - how they can become normal again?
- Next by Date: SBIRS, Ada and Ignorance
- Previous by thread: Re: Abnormal objects - how they can become normal again?
- Next by thread: GtkAda 2.4
- Index(es):