Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gfortran.dg/bind_c_usage_28.f90 @ 152:2b5abeee2509
update gcc11
author | anatofuz |
---|---|
date | Mon, 25 May 2020 07:50:57 +0900 |
parents | 84e7813d76e9 |
children |
line wrap: on
line source
! { dg-do compile } ! { dg-options "-std=f2008" } ! ! Contributed by Reinhold Bader ! use iso_c_binding type, bind(C) :: cstruct integer :: i end type interface subroutine psub(this) bind(c, name='Psub') ! { dg-error "Fortran 2018: Variable 'this' at .1. with POINTER attribute in procedure 'psub' with BIND.C." } import :: c_float, cstruct real(c_float), pointer :: this(:) end subroutine psub subroutine psub2(that) bind(c, name='Psub2') ! { dg-error "Fortran 2018: Variable 'that' at .1. with ALLOCATABLE attribute in procedure 'psub2' with BIND.C." } import :: c_float, cstruct type(cstruct), allocatable :: that(:) end subroutine psub2 end interface end