OSDN Git Service

2006-08-29 Steven G. Kargl <kargls@comcast.net>
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gfortran.dg / simpleif_2.f90
1 ! { dg-do compile }
2 ! Test fix for regression caused by 
3 ! 2006-06-23  Steven G. Kargl  <kargls@comcast.net>
4 !    PR fortran/27981
5 !    * match.c (gfc_match_if):  Handle errors in assignment in simple if.
6 !
7 module read
8   integer i, j, k
9   contains
10     subroutine a
11       integer, parameter :: n = 2
12       if (i .eq. 0) read(j,*) k
13       if (i .eq. 0) n = j    ! { dg-error "assign to a named constant" "" }
14     end subroutine a
15 end module read