structS1;// expected-note {{declared here}} expected-note{{forward declaration of 'S1'}}
externS1a;
classS2{
mutableinta;
public:
S2():a(0){}
S2(constS2&s2):a(s2.a){}
staticfloatS2s;
staticconstfloatS2sc;
};
constfloatS2::S2sc=0;
constS2b;
constS2ba[5];
classS3{
inta;
S3&operator=(constS3&s3);
public:
S3():a(0){}// expected-note {{candidate constructor not viable: requires 0 arguments, but 1 was provided}} expected-note {{candidate constructor not viable: requires 0 arguments, but 1 was provided}}
S3(S3&s3):a(s3.a){}// expected-note {{candidate constructor not viable: 1st argument ('const S3') would lose const qualifier}} expected-note {{candidate constructor not viable: 1st argument ('const S3') would lose const qualifier}}
};
constS3c;
constS3ca[5];
externconstintf;
classS4{
inta;
S4();
S4(constS4&s4);
public:
S4(intv):a(v){}
};
classS5{
inta;
S5():a(0){}
S5(constS5&s5):a(s5.a){}
public:
S5(intv):a(v){}
};
classS6{
inta;
public:
S6():a(0){}
};
S3h;
#pragma omp threadprivate(h) // expected-note {{defined as threadprivate or thread local}}
#pragma omp target teams distribute simd firstprivate(ba) allocate(omp_thread_mem_alloc: ba) // expected-warning {{allocator with the 'thread' trait access has unspecified behavior on 'target teams distribute simd' directive}}
#pragma omp target teams distribute simd private(i), firstprivate(i) // expected-error {{private variable cannot be firstprivate}} expected-note {{defined as private}}
// le45-note@-1 {{defined as private}}
// FIXME: Error is dropped for OpenMP 5.0. Probably shouldn't be.
for(i=0;i<argc;++i)foo();// le45-error {{loop iteration variable in the associated loop of 'omp target teams distribute simd' directive may not be private, predetermined as linear}}
#pragma omp target teams distribute simd firstprivate(i)
for(j=0;j<argc;++j)foo();
#pragma omp target teams distribute simd firstprivate(i) // expected-note {{defined as firstprivate}}
for(i=0;i<argc;++i)foo();// expected-error {{loop iteration variable in the associated loop of 'omp target teams distribute simd' directive may not be firstprivate, predetermined as linear}}
#pragma omp target teams distribute simd firstprivate(j)
#pragma omp target teams distribute simd firstprivate(argc) map(argc) // le45-error {{firstprivate variable cannot be in a map clause in '#pragma omp target teams distribute simd' directive}} le45-note {{defined as firstprivate}}