comp.lang.ada
 help / color / mirror / Atom feed
From: husseinp@logica.co.uk (Paul Hussein)
Subject: Re: Interface programming
Date: 1996/08/19
Date: 1996-08-19T00:00:00+00:00	[thread overview]
Message-ID: <4v988h$drs@romeo.logica.co.uk> (raw)
In-Reply-To: 4v8pj1$7n2@hermes.acs.unt.edu


mantri@ponder.csci.unt.edu (Ramesh S. Mantri) wrote:
I think your pragma needs a corresponding interface name pragma.
>Hi,
>	Need help with interface programming. I need to invoke a 
>Square Root function in a program. So I tried interfacing to Fortran
>as follows :
>	procedure SOMEPROC is
>	  package FORT_LIB is
>	    function SQRT(X:FLOAT) return FLOAT;
>	  private
>	    pragma INTERFACE(FORTRAN, SQRT);
                 pragma INTERFACE_NAME ( SQRT, "fortran_SQRT" );
>	  end FORT_LIB;
>	  NUM : INTEGER;
>	  NUMROOT : FLOAT;
>	begin
>	  GET(NUM); 
>	  NUMROOT := SQRT(FLOAT(NUM));
>	end SOMEPROC;
>It is displaying a warning at the "pragma" line, and declaring "SQRT"
>as and undefined identifier, in the line "NUMROOT := SQRT(FLOAT(NUM));".
>If you have time, please take the trouble of informing me as to how to
>rectify this. Also, the warning dispayed at the "pragma" line reads
>approximately as : "... parameter types. SYSTEM.ADDRESS expected..."
>Thanks for your patience.
>--- Ramesh Mantri






  reply	other threads:[~1996-08-19  0:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-08-19  0:00 Interface programming Ramesh S. Mantri
1996-08-19  0:00 ` Paul Hussein [this message]
1996-08-19  0:00   ` Robert Dewar
1996-08-19  0:00 ` Robert Dewar
1996-08-21  0:00 ` Pascal Ledru
replies disabled

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