next up previous
Next: 2- External Identifiers Up: Interfacing Fortran and Previous: Interfacing Fortran and

1- Type Definitions

It is good style to use typedef names to map the Fortran data types to their C counterparts. Up to now all platforms are satisfied by a single set of definitions:

typedef int     INTEGER;
typedef INTEGER LOGICAL;
typedef float   REAL;
typedef double  DBLPREC;
typedef struct { REAL re; REAL im; } COMPLEX;

but, for example, a Fortran compiler with AUTODBL option for generation 64-bit code would require different mappings.



Janne Saarela
Mon May 22 15:43:10 METDST 1995