1 ! RUN: %python %S/test_errors.py %s %flang_fc1 -pedantic
4 !ERROR: Format statement must be labeled
8 2002 format(DC
, F8
.2
, 3I8
, Z8
)
9 2003 format( D C
, F
8 . 2 , 3 I
8 , 3 Z
8 )
11 2005 format(20P
,F10
.2
)
12 2006 format(20P7F10
.2
)
18 2012 format(2L2 : 2L2)
22 2013 format(A10
) ! ok to reference outside the if block
25 ! C1302 warnings; no errors
26 !WARNING: Expected ',' or ')' in format expression
28 !WARNING: Expected ',' or ')' in format expression
30 !WARNING: Expected ',' or ')' in format expression
32 !WARNING: Expected ',' or ')' in format expression
35 !ERROR: Expected ',' or ')' in format expression
36 2101 format(3I83Z8
, 'abc')
38 !ERROR: Expected ',' or ')' in format expression
39 2102 format( 3 I
8 3 Z
8 )
41 !ERROR: Expected ',' or ')' in format expression
44 !WARNING: Expected ',' or ')' in format expression
48 3002 format(5X
,*(2(A
)))
50 !ERROR: Unlimited format item list must contain a data edit descriptor
51 !WARNING: 'X' edit descriptor must have a positive position value
54 !ERROR: Unlimited format item list must contain a data edit descriptor
55 3102 format(5X
,*(2(/)))
57 !ERROR: Unlimited format item list must contain a data edit descriptor
58 3103 format(5X
, 'abc', *((:)))
60 !WARNING: 'X' edit descriptor must have a positive position value
63 !ERROR: List repeat specifier must be positive
64 !WARNING: 'X' edit descriptor must have a positive position value
65 !ERROR: 'DT' edit descriptor repeat specifier must be positive
66 4101 format(0(X
), 0dt
)
68 6001 format(((I0
, B0
)))
70 !ERROR: 'A' edit descriptor 'w' value must be positive
71 !ERROR: 'L' edit descriptor 'w' value must be positive
72 6101 format((A0
), ((L0
)))
74 !ERROR: 'L' edit descriptor 'w' value must be positive
75 6102 format((3(((L
0 0 0)))))
77 7001 format(17G8
.1
, 17G8
.1e3
)
79 !ERROR: Expected 'G' edit descriptor '.d' value
84 !ERROR: A 'G0' edit descriptor must not have an 'e' value
85 8101 format(9(G0
.5e1
))
87 !ERROR: A 'G0' edit descriptor must not have an 'e' value
88 8102 format(9(G0
.5 E
1))