comp.lang.ada
 help / color / mirror / Atom feed
From: Brian Rogoff <bpr@bpr.best.vwh.net>
Subject: Re: Sugestion to Multiple Inheritance
Date: Tue, 22 Jan 2002 16:55:51 +0000
Date: 2002-01-22T16:55:51+00:00	[thread overview]
Message-ID: <Pine.BSF.4.40.0201221650320.94084-100000@bpr.best.vwh.net> (raw)
In-Reply-To: <slrna4oi9e.kn.lutz@taranis.iks-jena.de>

No problem! It may be worthwhile for someone to resuscitate the RPI SGL
library, which is based on the STL. When last I checked, it was still a
bit buggy, and I would prefer to avoid controlled types except when
necessary, but there were some good ideas there, and (at least in C++) I
prefer the generic approach to the OO approaches.

IMHO OOP is not as important as the programming world has made it out to
be, and should be used a lot less than it is.

-- Brian

On Mon, 21 Jan 2002, Lutz Donnerhacke wrote:

> * Brian Rogoff wrote:
> >Yes, generics can do exactly that. Do you understand the signature idiom
> >in Ada 95?
>
> Now I start to understand. Thanx.
>
> >What you don't get, that tagged types give you, is the same kind of
> >polymorphism at run time. You pay for that run time capability with run
> >time dispatch and the overhead of tagging.
>
> Of course. I was looking for an abstraction require a full instantiation.
> Generics does this a small step later than abtract tagged types. (Besides
> using tagged types for saving multiple implementations.) Without class wide
> programming there is no run-time overhead, but a storage one.
>
> >So you parameterize over a forward iterator signature, which looks
> >something like this
> >
> >generic
> >    type Value_Type (<>) is limited private;
> >    type Pointer_Type is access Value_Type;
> >    type Iterator_Type is private;
> >
> >    with procedure Incr (Iterator : in out Iterator_Type) is <>;
> >    with function Succ (Iterator : in Iterator_Type)
> >                       return Iterator_Type is <>;
> >    with function Get_Value (Iterator : Iterator_Type)
> >                            return Value_Type is <>;
> >    with procedure Set_Value (Iterator : in out Iterator_Type;
> >                              Value : in Value_Type) is <>;
> >    with function Get_Pointer (Iterator : Iterator_Type)
> >                              return Pointer_Type is <>;
> >    with function "=" (X, Y : Iterator_Type)
> >                        return Boolean is <>;
> >package Forward_Iterator_Signature is
> >-- Look, no body! This is a signature package.
> >end Forward_Iterator_Signature;
>
> Understand. Thank you. This seems to be the way Booch is working.
>




  reply	other threads:[~2002-01-22 16:55 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-11 10:20 Sugestion to Multiple Inheritance Lutz Donnerhacke
2002-01-11 17:21 ` Stephen Leake
2002-01-11 17:53   ` Lutz Donnerhacke
2002-01-11 19:57     ` Stephen Leake
2002-01-17  8:28       ` Lutz Donnerhacke
2002-01-17 14:31         ` Stephen Leake
2002-01-17 14:54           ` Lutz Donnerhacke
2002-01-17 20:52             ` Jim Rogers
2002-01-11 18:07 ` Mark Lundquist
2002-01-11 18:14 ` Richard Riehle
2002-01-11 20:56   ` Hyman Rosen
2002-01-12  7:35     ` Richard Riehle
2002-01-13  6:37       ` Hyman Rosen
2002-01-14 13:58         ` John English
2002-01-14 16:27           ` Ole-Hjalmar Kristensen
2002-01-12  2:09   ` Will
2002-01-11 22:04 ` Matthew Heaney
2002-01-15 15:32   ` Hyman Rosen
2002-01-15 16:03     ` Lutz Donnerhacke
2002-01-18 19:03       ` Matthew Heaney
2002-01-21 11:23         ` Lutz Donnerhacke
2002-01-21 16:43           ` Brian Rogoff
2002-01-21 17:00             ` Lutz Donnerhacke
2002-01-22 16:55               ` Brian Rogoff [this message]
2002-01-23  8:58                 ` Dmitry A. Kazakov
2002-01-25  0:09                   ` Brian Rogoff
2002-01-28 16:23                     ` Dmitry A. Kazakov
2002-01-12  0:28 ` Nick Roberts
replies disabled

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