comp.lang.ada
 help / color / mirror / Atom feed
From: dewarr@my-dejanews.com
Subject: Re: Future Ada language revisions?
Date: 1998/10/05
Date: 1998-10-05T00:00:00+00:00	[thread overview]
Message-ID: <6vbhcd$5jb$1@nnrp1.dejanews.com> (raw)
In-Reply-To: Pine.BSF.4.02A.9810050914220.9326-100000@shell5.ba.best.com

In article <Pine.BSF.4.02A.9810050914220.9326-100000@shell5.ba.best.com>,
  Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> Actually Alfred, Ada 95 *does* support the equivalent of C function
> pointers, although you'll have to use the Ada terminology "access to
> subprogram" to find them.
>
> If you really want to be a trouble-maker, you'll complain that the
> limitations on them make them only as powerful as C's function pointers,
> and less powerful than Pascal's function arguments (terminology?), and in
> that case I can point you directly to the long arguments on why they are
> so restricted :-)


Well Brian has a (well known to us here) axe to grind here, but the above is
a bit misleading. In fact in most respects the access-to-procedure values of
Ada are far more powerful than the procedure parameters of Pascal, in that
they are non-limited types that can be freely assigned. Yes it is true that
there are some limitations on the use of procedure parameters referring to
nested procedures, but on the other hand, many of the purposes for which
procedure parameters are used in Pascal are preferably implemented using
generics in the case of Ada, which are far more powerful than anything
Pascal has to offer.

For a good idea of how the use of generics and access-to-procedure approaches
compare, look at the g-hesorg.ads/adb and g-hesora.ads/adb files in the GNAT
distribution, these are respectively a generic and access-to-procedure
implementation of an optimized heapsort that does N log N comparisons (instead
of the usual 2 N log N).

-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own    




  reply	other threads:[~1998-10-05  0:00 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-09-27  0:00 Future Ada language revisions? bpr5549
1998-09-27  0:00 ` Larry Kilgallen
1998-09-27  0:00   ` Brian Rogoff
1998-09-28  0:00     ` Michael F Brenner
1998-09-28  0:00       ` dewarr
1998-09-28  0:00     ` dewarr
1998-09-28  0:00       ` Brian Rogoff
1998-09-29  0:00         ` Larry Kilgallen
1998-09-29  0:00         ` Michael F Brenner
1998-10-02  0:00           ` Fergus Henderson
1998-09-28  0:00   ` Arthur Evans Jr
1998-09-28  0:00     ` dewarr
1998-09-28  0:00 ` dewar
1998-10-05  0:00   ` Alfred Hilscher
1998-10-05  0:00     ` Brian Rogoff
1998-10-05  0:00       ` dewarr [this message]
1998-10-05  0:00     ` dewarr
1998-10-06  0:00       ` Alfred Hilscher
1998-10-05  0:00     ` Tucker Taft
1998-10-02  0:00 ` Robert I. Eachus
1998-10-03  0:00   ` Brian Rogoff
1998-10-05  0:00     ` dewarr
1998-10-04  0:00       ` Brian Rogoff
1998-10-05  0:00         ` Martin Dowie
1998-10-05  0:00           ` dewarr
1998-10-05  0:00           ` Niklas Holsti
1998-10-05  0:00             ` Martin Dowie
1998-10-06  0:00           ` dennison
1998-10-06  0:00           ` dennison
1998-10-06  0:00             ` dewarr
1998-10-06  0:00               ` Martin Dowie
1998-10-06  0:00             ` Martin Dowie
1998-10-06  0:00           ` r_barton1
1998-10-06  0:00         ` Matthew Heaney
1998-10-06  0:00     ` Robert I. Eachus
1998-10-06  0:00       ` Brian Rogoff
1998-10-07  0:00       ` dewarr
     [not found] ` <tgmF02yDo.A84@netcom.com>
1998-10-06  0:00   ` Matthew Heaney
1998-10-08  0:00 ` dennison
1998-10-08  0:00   ` Pat Rogers
1998-10-08  0:00   ` Brian Rogoff
1998-10-09  0:00     ` dennison
1998-10-16  0:00   ` Robert A Duff
  -- strict thread matches above, loose matches on Subject: below --
1998-10-21  0:00 Van Snyder
1998-10-22  0:00 ` Robert A Duff
1998-10-21  0:00   ` Brian Rogoff
1998-10-23  0:00     ` Robert I. Eachus
1998-10-29  0:00     ` Robert A Duff
1998-10-30  0:00       ` 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