comp.lang.ada
 help / color / mirror / Atom feed
From: Robert A Duff <bobduff@world.std.com>
Subject: Re: Pb with use of redefined "=" operator
Date: 1998/11/09
Date: 1998-11-09T00:00:00+00:00	[thread overview]
Message-ID: <wcchfw8sfg2.fsf@world.std.com> (raw)
In-Reply-To: 71tee6$pi5$1@nnrp1.dejanews.com

dewarr@my-dejanews.com writes:

> There is of course the currently fashionable code-bloat style of programming
> where no one cares if their programs run slowly and take up too much memory,
> but the trouble is that if you write standard packages in this style, it very
> much restricts the uses they can be put to...

I very much agree with the above (I hate buying new hardware that's 2
times faster, and then finding that it's only 1.1 times faster in
practise because the new software that goes with it makes up for the
speed gains), but:

>...(in many embedded and safety
> critical applications, tagged types are eliminated for good reasons!)

I disagree with that part.  Making a type tagged adds one word of
storage to each object of the type, in typical implementations of Ada.
It's quite easy to decide on a case-by-case basis whether that's "too
much".

There might be reasons to forbid the 'Class attribute in certain
safety-critical applications, but I see no reason to forbid "tagged".
Tagged types (without 'Class) don't introduce any dynamic dispatching or
anything else that might be of concern.

I've heard some safety-critical folks talking about not using "tagged"
because it introduces dynamic dispatching.  But that's a
misunderstanding of the language -- if you want to prevent dynamic
dispatching, then forbid 'Class.

- Bob
-- 
Change robert to bob to get my real email address.  Sorry.




  reply	other threads:[~1998-11-09  0:00 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-11-03  0:00 Pb with use of redefined "=" operator Fran�oise & Herv� BITTEUR
1998-11-04  0:00 ` Matthew Heaney
1998-11-04  0:00   ` Mats Weber
1998-11-05  0:00     ` Matthew Heaney
1998-11-05  0:00       ` Mats Weber
1998-11-05  0:00         ` Matthew Heaney
1998-11-09  0:00           ` Robert A Duff
1998-11-09  0:00             ` Brian Rogoff
1998-11-10  0:00               ` Robert A Duff
1998-11-10  0:00             ` Robert I. Eachus
1998-11-05  0:00       ` dewarr
1998-11-05  0:00         ` Matthew Heaney
1998-11-06  0:00           ` dewarr
1998-11-09  0:00             ` Robert A Duff [this message]
1998-11-10  0:00               ` dennison
1998-11-10  0:00                 ` Robert A Duff
1998-11-04  0:00 ` dewarr
1998-11-04  0:00   ` Tucker Taft
1998-11-04  0:00 ` Mats Weber
1998-11-04  0:00   ` Fran�oise & Herv� BITTEUR
replies disabled

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