diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gfortran.dg/assumed_rank_8_c.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gfortran.dg/assumed_rank_8_c.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gfortran.dg/assumed_rank_8_c.c b/gcc-4.9/gcc/testsuite/gfortran.dg/assumed_rank_8_c.c new file mode 100644 index 000000000..3910d318e --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gfortran.dg/assumed_rank_8_c.c @@ -0,0 +1,25 @@ +/* Called by assumed_rank_8.f90 and assumed_rank_9.f90. */ + +#include <stdlib.h> /* For abort(). */ + +struct a { + int *dat; +}; + +struct b { + struct a _data; +}; + + +void check_ (struct a *x) +{ + if (*x->dat != 489) + abort (); +} + + +void check2_ (struct b *x) +{ + if (*x->_data.dat != 489) + abort (); +} |