1 // RUN: %clang_cc1 -verify -fopenmp -ferror-limit 100 -o - %s -Wuninitialized
3 // RUN: %clang_cc1 -verify -fopenmp-simd -ferror-limit 100 -o - %s -Wuninitialized
8 bool foobool(int argc
) {
12 struct S1
; // expected-note {{declared here}}
18 S2
&operator=(S2
&s2
) { return *this; }
25 S3
&operator=(S3
&s3
) { return *this; }
30 S4
&operator=(const S4
&s4
); // expected-note {{implicitly declared private here}}
38 S5
&operator=(const S5
&s5
) { return *this; } // expected-note {{implicitly declared private here}}
53 #pragma omp threadprivate(h, k, l, m)
57 #pragma omp threadprivate(x)
63 int main(int argc
, char **argv
) {
66 #pragma omp teams distribute parallel for copyin // expected-error {{expected '(' after 'copyin'}}
67 for (i
= 0; i
< argc
; ++i
)
70 #pragma omp teams distribute parallel for copyin( // expected-error {{expected expression}} expected-error {{expected ')'}} expected-note {{to match this '('}}
71 for (i
= 0; i
< argc
; ++i
)
74 #pragma omp teams distribute parallel for copyin() // expected-error {{expected expression}}
75 for (i
= 0; i
< argc
; ++i
)
78 #pragma omp teams distribute parallel for copyin(k // expected-error {{expected ')'}} expected-note {{to match this '('}}
79 for (i
= 0; i
< argc
; ++i
)
82 #pragma omp teams distribute parallel for copyin(h, // expected-error {{expected expression}} expected-error {{expected ')'}} expected-note {{to match this '('}}
83 for (i
= 0; i
< argc
; ++i
)
86 #pragma omp teams distribute parallel for copyin(argc > 0 ? argv[1] : argv[2]) // expected-error {{expected variable name}}
87 for (i
= 0; i
< argc
; ++i
)
90 #pragma omp teams distribute parallel for copyin(l) // expected-error {{'operator=' is a private member of 'S4'}}
91 for (i
= 0; i
< argc
; ++i
)
94 #pragma omp teams distribute parallel for copyin(S1) // expected-error {{'S1' does not refer to a value}}
95 for (i
= 0; i
< argc
; ++i
)
98 #pragma omp teams distribute parallel for copyin(argv[1]) // expected-error {{expected variable name}}
99 for (i
= 0; i
< argc
; ++i
)
102 #pragma omp teams distribute parallel for copyin(i) // expected-error {{copyin variable must be threadprivate}}
103 for (i
= 0; i
< argc
; ++i
)
106 #pragma omp teams distribute parallel for copyin(m) // expected-error {{'operator=' is a private member of 'S5'}}
107 for (i
= 0; i
< argc
; ++i
)
110 #pragma omp teams distribute parallel for copyin(ST<int>::s, B::x) // expected-error {{copyin variable must be threadprivate}}
111 for (i
= 0; i
< argc
; ++i
)