URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [c_f_pointer_tests_2.f03] - Rev 774
Go to most recent revision | Compare with Previous | Blame | View Log
! { dg-do compile }! This should compile. There was a bug in resolving c_f_pointer that was! caused by not sorting the actual args to match the order of the formal args.! PR fortran/32800!FUNCTION C_F_STRING(CPTR) RESULT(FPTR)USE ISO_C_BINDINGimplicit noneTYPE(C_PTR), INTENT(IN) :: CPTR ! The C addressCHARACTER(KIND=C_CHAR), DIMENSION(:), POINTER :: FPTRINTERFACEFUNCTION strlen(string) RESULT(len) BIND(C,NAME="strlen")importTYPE(C_PTR), VALUE :: string ! A C pointerinteger(c_int) :: lenEND FUNCTION strlenEND INTERFACECALL C_F_POINTER(FPTR=FPTR, CPTR=CPTR,SHAPE=[strlen(cptr)])END FUNCTION C_F_STRING
Go to most recent revision | Compare with Previous | Blame | View Log
