From: Thierry Lelegard <thierry.lelegard@canal-plus.fr>
Subject: Re: How pass a "null" as a parameter of anonymous access type
Date: Fri, 23 Mar 2001 10:05:54 +0100
Date: 2001-03-23T10:05:54+01:00 [thread overview]
Message-ID: <3ABB11F2.C35C58FD@canal-plus.fr> (raw)
In-Reply-To: 3ABA5AC3.4C6C7536@t-online.de
[-- Attachment #1: Type: text/plain, Size: 846 bytes --]
> I want call a C-binding procedure which is defined as "procedure p (a :
> access X; b : access Y);"
> Both a or b may be a null pointer, but Ada say "null not allowed for
> anonymous access type".
> Any idea what to do ?
A hack (it works with GNAT, but may not with others, not defined by the
language):
Null_Access : aliased X; -- don't access it !!
for Null_Access'Address use System.Null_Address;
....
P (Null_Access'Access, ...);
-Thierry
____________________________________________________________________________
Thierry Lelegard, "The Jazzing Troll", Email: thierry.lelegard@canal-plus.fr
CANAL+ Technologies, 34 place Raoul Dautry, 75516 Paris Cedex 15, France
Tel: +33 1 71 71 54 30 Fax: +33 1 71 71 52 08 Mobile: +33 6 03 00 65 75
____________________________________________________________________________
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Carte pour Thierry Lelegard --]
[-- Type: text/x-vcard; charset=us-ascii; name="thierry.lelegard.vcf", Size: 333 bytes --]
begin:vcard
n:Lel�gard;Thierry
tel;cell:+33 6 03 00 65 75
tel;fax:+33 1 71 71 52 08
tel;work:+33 1 71 71 54 30
x-mozilla-html:FALSE
url:www.canalplus-technologies.com
org:Canal+ Technologies
adr:;;34, Place Raoul Dautry;Paris;;75516;France
version:2.1
email;internet:thierry.lelegard@canal-plus.fr
fn:Thierry Lel�gard
end:vcard
next prev parent reply other threads:[~2001-03-23 9:05 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-03-22 20:04 How pass a "null" as a parameter of anonymous access type Freddy
2001-03-22 21:02 ` tmoran
2001-03-25 21:32 ` Freddy
2001-03-26 14:31 ` How pass a Ted Dennison
2001-03-23 9:05 ` Thierry Lelegard [this message]
2001-03-25 21:33 ` How pass a "null" as a parameter of anonymous access type Freddy
2001-03-26 19:17 ` Mark Lundquist
2001-03-27 16:13 ` Alfred Hilscher
2001-03-27 16:53 ` Thierry Lelegard
2001-03-26 13:44 ` Marc A. Criley
2001-03-26 19:35 ` Mark Lundquist
2001-03-27 12:59 ` Marc A. Criley
2001-03-27 16:12 ` Alfred Hilscher
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox