1 /* Check -ff2c calling conventions
2 Return value of COMPLEX function is via an extra argument in the
3 calling sequence that points to where to store the return value
4 Additional underscore appended to function name
6 Simplified from f2c output and tested with g77 */
9 typedef double doublereal
;
10 typedef struct { real r
, i
; } complex;
11 typedef struct { doublereal r
, i
; } doublecomplex
;
13 extern double f2c_4b__(double *);
14 extern void f2c_4d__( complex *, complex *);
15 extern void f2c_4f__( complex *, int *,complex *);
16 extern void f2c_4h__( doublecomplex
*, doublecomplex
*);
17 extern void f2c_4j__( doublecomplex
*, int *, doublecomplex
*);
18 extern void abort (void);
24 if ( a
!= b
) abort();
31 f2c_4d__(&ret_val
,&x
);
32 if ( x
.r
!= ret_val
.r
&& x
.i
!= ret_val
.i
) abort();
40 f2c_4f__(&ret_val
,&i
,&x
);
41 if ( x
.r
!= ret_val
.r
&& x
.i
!= ret_val
.i
) abort();
45 doublecomplex x
,ret_val
;
48 f2c_4h__(&ret_val
,&x
);
49 if ( x
.r
!= ret_val
.r
&& x
.i
!= ret_val
.i
) abort();
53 doublecomplex x
,ret_val
;
57 f2c_4j__(&ret_val
,&i
,&x
);
58 if ( x
.r
!= ret_val
.r
&& x
.i
!= ret_val
.i
) abort();
61 void f2c_4k__(complex *ret_val
, complex *x
) {
66 void f2c_4l__(complex *ret_val
, int *i
, complex *x
) {
71 void f2c_4m__(doublecomplex
*ret_val
, doublecomplex
*x
) {
76 void f2c_4n__(doublecomplex
*ret_val
, int *i
, doublecomplex
*x
) {