comp.lang.ada
 help / color / mirror / Atom feed
From: jls@yoda.Rational.COM (Jim Showalter)
Subject: Re: Calling Ada routines from C programs.
Date: 18 Feb 91 00:23:37 GMT	[thread overview]
Message-ID: <jls.666836617@yoda> (raw)
In-Reply-To: 1884@array.UUCP

mark@array.UUCP (Mark Culp) writes:

I believe you are trying to do this backwards. Pragma Interface allows
Ada to call other languages. I do not believe the LRM specifies how
OTHER languages are to call Ada--that would seem to be more the job
of the linker for the other language than of Ada.

Thus, in your example you have written the Ada Test_C_Interface to be able to
call a C function called "C_Main_Routine". This should work (presuming
you have tools sufficient to link the two languages). But then you try
to call ada_routine from your C program. Does your C linker know how
to do this? If not, this won't work. 
--
***** DISCLAIMER: The opinions expressed herein are my own. Duh. Like you'd
ever be able to find a company (or, for that matter, very many people) with
opinions like mine. 
                   -- "When I want your opinion, I'll beat it out of you."

  reply	other threads:[~1991-02-18  0:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1991-02-15 18:14 Calling Ada routines from C programs Mark Culp
1991-02-18  0:23 ` Jim Showalter [this message]
1991-02-18 16:14   ` Karl Keyte
1991-02-19 15:05     ` David Emery
1991-02-19 19:37       ` Bruce Bauman
replies disabled

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