2 ! { dg-options "-std=f2008 " }
5 ! Check for correct behavior of EXIT / CYCLE combined with non-loop
6 ! constructs at run-time.
8 ! Contributed by Daniel Kraft, d@domob.eu.
17 CLASS(t), ALLOCATABLE :: var
19 ! EXIT and CYCLE without names always refer to innermost *loop*. This
20 ! however is checked at run-time already in exit_1.f08.
22 ! Basic EXITs from different non-loop constructs.
25 myif: IF (i == 1) THEN
36 mysel: SELECT CASE (i)
48 mycharsel: SELECT CASE ("foobar")
65 myassoc: ASSOCIATE (x => 5 + 2)
71 mytypesel: SELECT TYPE (var)
80 ! Check EXIT with nested constructs.
82 inner: IF (.TRUE.) THEN