comp.lang.ada
 help / color / mirror / Atom feed
From: mole-end!mat@uunet.uu.net
Subject: Re: Multiple Inheritance in Ada 9X/Pointers?
Date: 10 Jan 92 01:39:27 GMT	[thread overview]
Message-ID: <1992Jan10.013927.10479@mole-end> (raw)

In article <1992Jan8.225611.3226@cis.ohio-state.edu>, weide@elephant.cis.ohio-s
tate.edu (Bruce Weide) writes:
> In article <kmmlhbINNmqt@agate.berkeley.edu>
> hilfingr@tully.CS.Berkeley.EDU (Paul N. Hilfinger) writes:
. . .
> >Here, likewise, the more interesting topic is "what dynamic data types
> >SHOULD we use for applications where we now use pointers?"
 
> Yes, this is (part of) the question I was proposing ...  Let me try again:
> "What abstractions should we use to replace pointers?"

> Another part of the question is something like, "What useful abstractions
> require direct use of pointers for their (efficient) implementation?"

Another useful question is ``How can we mitigate the whatever danger arises
from pointers?''
 
 . . .

> ... I'd argue ... if pointers must be used in the representation of some
> abstraction, then at least this fact should not be discernible to the
> client of that abstraction.  ...  then the uses of pointers may be buried
> deep in the ... software system, where ... they can be kept under control.
> The pointers need not percolate all the way up to higher-level
> abstractions.  ...

Here's a question: how many uses of pointers (or unchecked array bounds,
which are nearly as dangerous) can be stereotyped?  How many of those can
be written as templates, to be coded once, gotten right, and never coded
again?  Yes, that's what they said about subroutines, but they didn't
realize that the world is made of more than integers.

Other measures are possible: `pointer' types that MUST be initialized,
indexing types whose values can only be created by functions under control
of whoever `owns' the data structure, &c.

It will probably be easier to do these things for the elements of code that
derive from --programming-- technology, not those that derive from features
of the problem or the subject matter.  (But --code-- that derives from
subject matter libraries is a mixture of problem-specific and code-specific
features.)  I can't speak for features that derive from the environment or
resources surrounding the program.

Of course, whomsoever codes the AVL or 2-3 or Lempel-Ziv templates had
better get them right--and whomsoever codes them as anything but templates
is a selfish, shortsighted wastrel, not unlike those who burn rainforest
to get 1-year cropland.  (My opinion, I know, so flame gently please.)
-- 
 (This man's opinions are his own.)
 From mole-end				Mark Terribile

 uunet!mole-end, Somewhere in Matawan, NJ

             reply	other threads:[~1992-01-10  1:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1992-01-10  1:39 mole-end!mat [this message]
  -- strict thread matches above, loose matches on Subject: below --
1992-01-15 14:04 Multiple Inheritance in Ada 9X/Pointers? Guido van Rossum
1992-01-14  9:21 Jean-Pierre Rosen
1992-01-09  2:59 bu.edu!rpi!zaphod.mps.ohio-state.edu!caen!uvaarpa!software.org!blakemor
1992-01-09  0:18 Paul Barton-Davis
1992-01-08 22:56 micro-heart-of-gold.mit.edu!wupost!zaphod.mps.ohio-state.edu!cis.ohio-sta
1992-01-08 19:51 agate!tully.CS.Berkeley.EDU!hilfingr
1992-01-08 15:38 ub!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!elephant.cis.ohio-state.e
replies disabled

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