Silverfrost Forums

Welcome to our forums

Reporting a bug in Win32 VC interoperability example#2

2 Oct 2007 6:49 #2279

In folder C:\Program Files\Silverfrost\FTN95\demo\win32\visualcinteroperability2\vcproject1

File 'vcproject1.cpp', line 81, extern 'C' DllExport void _FunctionArgumentsReference(int *i, double *x) the type of *x should be changed to 'float', which corresponds to 'real' in FORTRAN. Otherwise, the program will not run as intended.

Comparison of FORTRAN and C/C++ datatypes: http://www.yolinux.com/TUTORIALS/LinuxTutorialMixingFortranAndC.html

9 Oct 2007 8:57 #2341

Yes you are right, double would correspond to REAL*8, which is not used in this example. The example has been changed to float.

Please login to reply.