summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/misplaced_statement.f90
blob: 63f33422ffc88b8355fd2406579a1aa3e830dba2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
!{ dg-do compile }
! PR fortran/66040
!
! Original code from Gerhard Steinmetz
! <gerhard dot steinmetz dot fortran at t-online dot de>
real function f1(x)
   sequence          ! { dg-error "Unexpected SEQUENCE statement" }
end function f1

real function f2()
   else              ! { dg-error "Unexpected ELSE statement" }
end function f2

real function f3()
   block data        ! { dg-error "Unexpected BLOCK DATA statement" }
end function f3

real function f4()
   program p         ! { dg-error "Unexpected PROGRAM statement" }
end function f4