Actual source code: f90_solaris_old.h

      2: #if !defined (__F90_SOLARIS_OLD_H)
      4:
      5: typedef struct {
      6:   long lower;   /* starting index of the fortran array */
      7:   long extent;  /* length of the array */
      8:   long mult;    /* in bytes for char,32 bit words for others. Why???? */
      9: } tripple;

     11: /*
     12:   The following constants are just
     13:   guesses. The program behavies strangly
     14:   if these constants are not set in
     15:   the f90 pointer
     16: */
     17: #define F90_CHAR_ID    100665344
     18: #define F90_INT_ID     35659784
     19: #define F90_DOUBLE_ID  58736640
     20: #define F90_COMPLEX_ID 68190216
     21: #define F90_COOKIE     36864

     23: #if !defined (PETSC_COMPLEX)
     24: #define F90_SCALAR_ID F90_DOUBLE_ID
     25: #else
     26: #define F90_SCALAR_ID F90_COMPLEX_ID
     27: #endif

     30: #define f90_header() \
     31: void*          addr;    /* Pointer to the data */ \
     32: int            sd;      /* sizeof(DataType) in bits */  \
     33: unsigned short cookie;  /* a wierd f90 cookie */ \
     34: unsigned short ndim;    /* No of dimensions */          \
     35: int            id;      /* integer id representing the datatype */ \
     36: int            a,b;     /* unknown stuff - always zero. */

     38: typedef struct {
     39:   f90_header()
     40:   tripple dim[1];
     41: }F90Array1d;

     43: typedef struct {
     44:   f90_header()
     45:   tripple dim[2];   /* dim1,dim2 */
     46: }F90Array2d;

     48: typedef struct {
     49:   f90_header()
     50:   tripple dim[3];   /* dim1,dim2,dim3 */
     51: }F90Array3d;

     53: typedef struct {
     54:   f90_header()
     55:   tripple dim[4];   /* dim1,dim2,dim3,dim4 */
     56: }F90Array4d;

     58: #endif