* cfghooks.c (verify_flow_info): Disable check that all probabilities
[official-gcc.git] / gcc / testsuite / gfortran.dg / keyword_symbol_1.f90
blob2661897fff5ba23b1fa269b51a621588dc5a9e16
1 ! { dg-do compile }
2 ! This tests the fix for PR28526, in which a public interface named
3 ! 'end' would be treated as a variable because the matcher tried
4 ! 'END INTERFACE' as an assignment and left the symbol modified in
5 ! failing. The various pitfalls that were encountered in developing
6 ! the fix are checked here.
8 ! Contributed by Paul Thomas <pault@gcc.gnu.org>
10 module blahblah
11 public function, end
13 ! The original PR from Yusuke IGUCHI <iguchi@coral.t.u-tokyo.ac.jp>
14 interface end
15 module procedure foo1
16 end interface
18 ! A contribution to the PR from Tobias Schlueter <tobi@gcc.gnu.org>
19 interface function
20 module procedure foo2 ! { dg-error "is neither function nor" }
21 end interface
23 interface function
24 module procedure foo3
25 end interface
27 interface
28 function foo4 ()
29 real foo4
30 x = 1.0 ! { dg-error "in INTERFACE" }
31 end function foo4
32 end interface
34 interface
35 x = 2.0 ! { dg-error "in INTERFACE block" }
36 function foo5 ()
37 real foo5
38 end function foo5
39 end interface
41 x = 3.0 ! { dg-error "in MODULE" }
43 contains
45 subroutine foo1
46 end subroutine foo1
48 function foo2 ! { dg-error "Expected formal argument list" }
49 foo2 = 0 ! { dg-error "already been host associated" }
50 end function foo2 ! { dg-error "Expecting END MODULE" }
52 function foo3 ()
53 real foo3
54 end function foo3
56 x = 4.0 ! { dg-error "in CONTAINS section" }
57 end module blahblah