comp.lang.ada
 help / color / mirror / Atom feed
From: mg@harp.camb.inmet.com (Mitch Gart)
Subject: Re: Converting C++ class to Ada
Date: 1996/12/20
Date: 1996-12-20T00:00:00+00:00	[thread overview]
Message-ID: <E2ptyG.GIu.0.-s@inmet.camb.inmet.com> (raw)
In-Reply-To: JSA.96Dec19214712@alexandria


Jon S Anthony (jsa@alexandria) wrote:

: CE is raised if a null value is passed to an access _parameter_.  
(snip)
: A good thing IMO on both counts.  See in particular 11.5(11)

I think this is a mistake in Ada 95.  Not allowing null for an
access parameter makes it harder to interface to C:

    procedure P(param: access thing);
    pragma import(C, P);

You can't call P(null) even though the C function may have 
semantics defined for null.  You have to make up a named
access type for the parameter.

Users of Win32Ada and X11Ada will notice that the bindings
contain access parameters in many places.  This is a mistake
that needs fixing given the above Ada 95 rule.

- Mitch Gart
- mg@inmet.com




  reply	other threads:[~1996-12-20  0:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-12-10  0:00 Converting C++ class to Ada Ken Garlington
1996-12-11  0:00 ` Jon S Anthony
1996-12-12  0:00   ` Ken Garlington
1996-12-18  0:00   ` Jon S Anthony
1996-12-18  0:00     ` Matthew Heaney
1996-12-19  0:00     ` Robert A Duff
1996-12-20  0:00       ` Stephen Leake
1996-12-20  0:00         ` Robert A Duff
1996-12-20  0:00   ` Jon S Anthony
1996-12-20  0:00     ` Mitch Gart [this message]
1996-12-20  0:00   ` Norman H. Cohen
1996-12-21  0:00   ` Jon S Anthony
1996-12-11  0:00 ` Norman H. Cohen
1996-12-12  0:00   ` Jon S Anthony
1996-12-11  0:00 ` Stephen Leake
1996-12-13  0:00   ` Stephen Leake
1996-12-11  0:00 ` Larry Kilgallen
1996-12-12  0:00 ` Dale Stanbrough
1996-12-12  0:00   ` Constructors for Ada (was: Converting C++ class to Ada) Matthew Heaney
1996-12-13  0:00     ` Norman H. Cohen
1996-12-13  0:00       ` Matthew Heaney
1996-12-17  0:00   ` Robert I. Eachus
replies disabled

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