| 1 |
! { dg-do compile } |
| 2 |
! { dg-options "-std=f95" } |
| 3 |
|
| 4 |
! PR30481 Assumed size character is not allowed in namelist. |
| 5 |
! Test case from PR, submitted by Jerry DeLisle <[email protected]> |
| 6 |
! |
| 7 |
! Modifications for PR fortran/47339 / PR fortran/43062: |
| 8 |
! Add -std=f95, add bar() |
| 9 |
! |
| 10 |
subroutine foo(c) |
| 11 |
character*(*) c |
| 12 |
namelist /abc/ c ! { dg-error "nonconstant character length in namelist" } |
| 13 |
end subroutine |
| 14 |
|
| 15 |
subroutine bar(d,n) |
| 16 |
integer :: n |
| 17 |
character(len=n) d |
| 18 |
namelist /abcd/ d ! { dg-error "nonconstant character length in namelist" } |
| 19 |
end subroutine bar |
| 20 |
|