2 ! { dg-additional-sources pr32627_driver.c }
3 ! Verify that c_f_pointer exists for string arguments.
8 function get_c_string() bind(c)
9 use, intrinsic :: iso_c_binding, only: c_ptr
10 type(c_ptr) :: get_c_string
11 end function get_c_string
15 integer( c_int ) :: xc, yc
19 type( A ), pointer :: fptr
20 type( A ), target :: my_a_type
21 character( len=9 ), pointer :: strptr
25 fptr%str = get_c_string()
27 call c_f_pointer( fptr%str, strptr )
29 print *, 'strptr is: ', strptr