From: Jeffrey Creem <jeff@thecreems.com>
Subject: Re: Calling C++ from Ada
Date: Sat, 13 May 2006 13:02:33 -0400
Date: 2006-05-13T13:02:33-04:00 [thread overview]
Message-ID: <s1ghj3-e5m.ln1@newserver.thecreems.com> (raw)
In-Reply-To: <pan.2006.05.13.14.48.38.150776@laposte.net>
Yves Bailly wrote:
> Hello all,
>
> I'm trying to use C++ classes from an Ada program. Searching around, I
> found some examples, but none implying a non-default constructor.
> I tried some advices found in
> http://www.pegasoft.ca/resources/boblap/19.html#19.5, which work well,
> but it seems one can only use default constructors. Using various versions
> of GNAT (including the one coming with the latest GCC 4.2.0), when trying
> to use the pragma CPP_Constructor with a function taking more than zero
> parameters, I get this message :
> imported.ads:36:27: non-default constructors not implemented
>
> Does anyone have any clue about this ?
>
> Thanks and best regards,
>
> Yves Bailly
>
Direct interface to C++ from Ada is outside the scope of the Ada (at
least 95) LRM. GNAT has some vendor specific pragmas that can be used
but I have never heard of any widespread use of these pragmas in any
publically avaialble code.
There is a paper on the topic being presented at the GCC summit this summer
http://www.gccsummit.org/2006/view_abstract.php?content_key=26
In any case, outside of something heavy like an ORB or vendor specific
such as GNATCOM I have not seen anything that looks to promising in this
area yet.
You probably need to interface to it the same way a C programmer would -
with non classed based externs.
next prev parent reply other threads:[~2006-05-13 17:02 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-05-13 14:48 Calling C++ from Ada Yves Bailly
2006-05-13 17:02 ` Jeffrey Creem [this message]
2006-05-13 19:08 ` Yves Bailly
2006-05-13 19:55 ` Jeffrey Creem
2006-05-14 8:59 ` Yves Bailly
2006-05-14 13:39 ` Jeffrey Creem
2006-05-14 18:38 ` Jeffrey R. Carter
2006-05-15 15:24 ` rodkay
2006-05-15 16:23 ` Jeffrey Creem
2006-05-16 2:14 ` Gene
2006-05-16 4:31 ` rodkay
2006-05-16 11:47 ` Jeffrey Creem
2006-05-17 4:53 ` rodkay
2006-05-17 6:05 ` Martin Krischik
2006-05-25 5:34 ` rodkay
2006-05-25 11:29 ` Alex R. Mosteo
2006-05-29 3:43 ` Gene
2006-05-29 14:53 ` rodkay
2006-05-29 17:48 ` Martin Krischik
2006-05-13 22:38 ` Craig Carey
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox