comp.lang.ada
 help / color / mirror / Atom feed
From: Maciej Sobczak <see.my.homepage@gmail.com>
Subject: Re: High-Integrity OO and controlled types
Date: Tue, 3 May 2011 02:59:05 -0700 (PDT)
Date: 2011-05-03T02:59:05-07:00	[thread overview]
Message-ID: <f6e72476-0dca-4ab8-bfdf-94a0ddf7a7dc@j26g2000yqa.googlegroups.com> (raw)
In-Reply-To: beefc106-01b0-4dec-ae7b-2ef41b1c7c78@b19g2000yqg.googlegroups.com

On May 3, 11:32 am, Cyrille <co...@eu.adacore.com> wrote:

> > Excluding controlled types altogether sounded like throwing baby out
> > with the water, but now the motivations are a bit more clear to me.
>
> HI profiles are usually much more constrained. The first goal of this
> document is to gather the necessary information to make it possible to
> build a safety case when using tagged types and more generally OOP in
> a HI context. Usually those are banned along with almost all the
> "advanced" features of the language. So no baby thrown with the water.
> This is a the other way around: we put more water in the bath so that
> maybe one day we can consider bathing your "controlled" baby ;-)

I see. Note that between these two:

1. dynamically allocated class-wide (with open hierarchy) objects tied
to locally scoped storage pool with all resulting mess, and

2. limited controlled object on the stack as a way to hook scope exit
event

there is a *wide* spectrum of use cases, some of them being
unreasonable in the HI context, but some of them being entirely
justified.

I would very much welcome at least that second extreme above being
acknowledged as a valid programming pattern in safety critical
systems.

Another angle: the fact that the lack of controlled types in HI
profiles can be considered as a problem is entirely a result of the
fact that Ada completely screwed this aspect at the beginning.
Controlledness should not be based on tags - it should be a completely
orthogonal property of the type, without any relation to class-wide
objects and dispatching calls (see C++ for an example). Interestingly
this conclusion comes up regularly. Time to fix that part of the
language, perhaps? ;-)

--
Maciej Sobczak * http://www.msobczak.com * http://www.inspirel.com



  reply	other threads:[~2011-05-03  9:59 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-01 20:38 High-Integrity OO and controlled types Maciej Sobczak
2011-05-01 21:29 ` Robert A Duff
2011-05-01 22:44   ` Simon Wright
2011-05-02  7:59   ` Dmitry A. Kazakov
2011-05-02 16:32     ` Robert A Duff
2011-05-02 19:39       ` Dmitry A. Kazakov
2011-05-03  0:08         ` Robert A Duff
2011-05-03  7:30           ` Dmitry A. Kazakov
2011-05-03 16:51             ` Robert A Duff
2011-05-02  9:50 ` Cyrille
2011-05-02 10:01   ` Cyrille
2011-05-02 19:25     ` Maciej Sobczak
2011-05-03  9:32       ` Cyrille
2011-05-03  9:59         ` Maciej Sobczak [this message]
2011-05-03 10:24           ` Dmitry A. Kazakov
2011-05-03 16:53             ` Robert A Duff
2011-05-03 17:37               ` Dmitry A. Kazakov
2011-05-03 11:28           ` Georg Bauhaus
2011-05-03 12:27             ` Dmitry A. Kazakov
2011-05-03 15:22               ` Georg Bauhaus
2011-05-03 16:28                 ` Dmitry A. Kazakov
2011-05-04  8:48                   ` Georg Bauhaus
2011-05-04  9:28                     ` Dmitry A. Kazakov
2011-05-04 14:46                       ` Georg Bauhaus
2011-05-04 15:01                         ` Dmitry A. Kazakov
2011-05-04 15:25                           ` Georg Bauhaus
2011-05-04 16:23                             ` Dmitry A. Kazakov
2011-05-04 17:06                               ` Georg Bauhaus
2011-05-04 20:16                                 ` Dmitry A. Kazakov
2011-05-05  7:13                                   ` Maciej Sobczak
2011-05-05 10:58                                     ` Cyrille
2011-05-05 12:35                                       ` 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