[flang] Accept polymorphic component element in storage_size
[llvm-project.git] / flang / test / Semantics / if_construct01.f90
blob0d9cbe483d9d25b08e166845f747ae108e7e0e42
1 ! RUN: %python %S/test_errors.py %s %flang_fc1
2 ! Simple check that if constructs are ok.
4 if (a < b) then
5 a = 1
6 end if
8 if (a < b) then
9 a = 2
10 else
11 a = 3
12 endif
14 if (a < b) then
15 a = 4
16 else if(a == b) then
17 a = 5
18 end if
20 if (a < b) then
21 a = 6
22 else if(a == b) then
23 a = 7
24 elseif(a > b) then
25 a = 8
26 end if
28 if (a < b) then
29 a = 9
30 else if(a == b) then
31 a = 10
32 else
33 a = 11
34 end if
36 if (a < b) then
37 a = 12
38 else if(a == b) then
39 a = 13
40 else if(a > b) then
41 a = 14
42 end if
44 if (f()) then
45 a = 15
46 end if
48 contains
49 logical function f()
50 f = .true.
51 end
52 end