1 ! RUN: %python %S/test_errors.py %s %flang_fc1
2 ! C1123 -- Expressions in DO CONCURRENT header cannot reference variables
3 ! declared in the same header
6 INTEGER :: a
, i
, j
, k
, n
8 !ERROR: DO CONCURRENT mask expression references variable 'n' in LOCAL locality-spec
9 DO CONCURRENT (INTEGER *2 :: i
= 1:10, i
< j
+ n
) LOCAL(n
)
13 !ERROR: DO CONCURRENT mask expression references variable 'a' in LOCAL locality-spec
14 DO 30 CONCURRENT (i
= 1:n
:1, j
=1:n
:2, k
=1:n
:3, a
<3) LOCAL (a
)
19 !ERROR: DO CONCURRENT limit expression may not reference index variable 'j'
20 DO CONCURRENT (i
= j
:3, j
=1:3)
24 !ERROR: DO CONCURRENT limit expression may not reference index variable 'j'
25 DO CONCURRENT (i
= 1:j
, j
=1:3)
29 !ERROR: DO CONCURRENT step expression may not reference index variable 'j'
30 DO CONCURRENT (i
= 1:3:j
, j
=1:3)
33 !ERROR: DO CONCURRENT limit expression may not reference index variable 'i'
34 DO CONCURRENT (INTEGER*2 :: i
= 1:3, j
=i
:3)
37 END PROGRAM dosemantics04