comp.lang.ada
 help / color / mirror / Atom feed
From: "Jon Orris" <jonorris@ieee.org>
Subject: Re: C++ STL Components and Ada
Date: Tue, 17 Jul 2001 15:47:39 -0400
Date: 2001-07-17T19:46:38+00:00	[thread overview]
Message-ID: <9j24mu$fhq$1@bob.news.rcn.net> (raw)
In-Reply-To: 3B5450EF.7D82CCF5@worldnet.att.net

"James Rogers" <jimmaureenrogers@worldnet.att.net> wrote in message
news:3B5450EF.7D82CCF5@worldnet.att.net...
> Brian Rogoff wrote:
> > I wouldn't say they're the best thing since the invention of fire, but
C++
> > templates allow all sorts of interesting things, almost like macros, but
> > linked with the type system. They provide a crude form of parametric
> > polymorphism which doesn't have the overhead associated with typical
> > implementations of polymorphic languages. I can easily imagine an
Ada-like
> > language which steals some nice aspects of C++ templates.
> >
>
> C++ templates also have the disadvantage that their instantiations
> cannot
> be checked by the compiler. Instead, you must deal with runtime errors
> when making simple mistakes such as filling a container with values
> of Animal and then trying to read them out as values of Mineral.

Could you provide an example of what you mean here? I've seen this claim
before, and have been unable to think of how this would occur. I've never
had this sort of issue crop up when developing in C++.

Jon Orris
jonorris@ieee.org






  reply	other threads:[~2001-07-17 19:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-16  0:37 C++ STL Components and Ada James Rogers
2001-07-17  4:26 ` Brian Rogoff
2001-07-17 14:48   ` James Rogers
2001-07-17 19:47     ` Jon Orris [this message]
2001-07-18  3:09       ` James Rogers
2001-07-18 15:48         ` Matthias Benkmann
2001-07-18 18:00         ` Jon Orris
2001-07-19 20:48     ` Ray Blaak
2001-07-20  0:40       ` Brian Rogoff
replies disabled

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