1 !RUN: %python %S/../test_errors.py %s %flang -fopenmp -fopenmp-version=52 -Werror
5 !PORTABILITY: The specification of modifiers without comma separators for the 'MAP' clause has been deprecated in OpenMP 5.2
6 !$omp target map(always, present close, to: x)
13 !PORTABILITY: The specification of modifiers without comma separators for the 'MAP' clause has been deprecated in OpenMP 5.2
14 !$omp target map(always, present, close to: x)
21 !WARNING: Duplicate map-type-modifier entry 'PRESENT' will be ignored
22 !$omp target map(always, present, close, present, to: x)
29 !ERROR: The iterator variable must be of integer type
30 !ERROR: Must have INTEGER type, but is REAL(4)
31 !$omp target map(present, iterator(real :: i = 1:10), to: x(i))
38 !ERROR: The begin and end expressions in iterator range-specification are mandatory
39 !$omp target map(present, iterator(integer :: i = :10:1), to: x(i))
46 !ERROR: The begin and end expressions in iterator range-specification are mandatory
47 !$omp target map(present, iterator(integer :: i = 1:), to: x(i))
54 !ERROR: The begin and end expressions in iterator range-specification are mandatory
55 !$omp target map(present, iterator(integer :: i = 1::-1), to: x(i))
62 !WARNING: The step value in the iterator range is 0
63 !$omp target map(present, iterator(integer :: i = 1:2:0), to: x(i))
70 !WARNING: The begin value is less than the end value in iterator range-specification with a negative step
71 !$omp target map(present, iterator(integer :: i = 1:10:-2), to: x(i))
78 !WARNING: The begin value is greater than the end value in iterator range-specification with a positive step
79 !$omp target map(present, iterator(integer :: i = 12:1:2), to: x(i))
86 !ERROR: 'iterator' modifier cannot occur multiple times
87 !$omp target map(present, iterator(i = 1:2), iterator(j = 1:2), to: x(i + j))
94 !ERROR: 'map-type' should be the last modifier
95 !$omp target map(present, from, iterator(i = 1:10): x(i))