3 #include <ISO_Fortran_binding.h>
6 extern int do_loop(CFI_cdesc_t
* array
);
8 int main(int argc
, char ** argv
)
15 memset(arr
,0,sizeof(int)*nx
*ny
*nz
);
22 int rc
= CFI_establish((CFI_cdesc_t
*)&farr
, arr
, CFI_attribute_other
, CFI_type_int
, 0, (CFI_rank_t
)3, (const CFI_index_t
*)shape
);
23 if (rc
!= CFI_SUCCESS
) abort();
24 int result
= do_loop((CFI_cdesc_t
*)&farr
);
25 if (result
!= nx
*ny
*nz
) abort();