2 ! { dg-options "-std=f95" }
4 ! This tests the patch for PR25024.
6 ! PR25024 - The external attribute for subroutine a would cause an ICE.
8 EXTERNAL A
! { dg-error "EXTERNAL attribute conflicts with SUBROUTINE" }
11 function ext (y
) ! { dg-error "EXTERNAL attribute conflicts with FUNCTION" }
19 external z
! OK no conflict
25 external ext
! OK, valid external reference.
26 external main
! { dg-error "PROGRAM attribute conflicts with EXTERNAL" }
31 end function ext1
! { dg-error "Duplicate EXTERNAL attribute" }
38 function inv (y
) ! { dg-error "EXTERNAL attribute conflicts with FUNCTION" }