Commit 0c541bde authored by Budiardja, Reuben's avatar Budiardja, Reuben
Browse files

Added simpler test case for C_Descriptor

parent 56e6e8ce
#include <stdlib.h>
#include <stdio.h>
#include "ISO_Fortran_binding.h"
void C_Desc ( CFI_cdesc_t *A_DV )
{
printf("A_DV.rank: %d\n", A_DV->rank );
}
module C_DescMod
use iso_c_binding
implicit none
public
interface
subroutine C_Desc ( A ) bind ( c, name = 'C_Desc' )
use iso_c_binding
implicit none
real, dimension ( :, :, : ), allocatable, &
intent ( out ) :: &
A
end subroutine C_Desc
end interface
end module C_DescMod
program C_DescProg
use C_DescMod
implicit none
real, dimension ( :, :, : ), allocatable :: &
Array
print*, 'Fortran: rank:', rank ( Array )
call C_Desc ( Array )
end program C_DescProg
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment