summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/gomp/pr35328.C
blob: 718283b5957fd86b0180be9bd779d9dc1cb29ebf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// PR c++/35328
// { dg-do compile }
// { dg-options "-fopenmp" }

struct A
{
  ~A ()();		// { dg-error "declared as function returning a function" }
};
struct B
{
  B ()();		// { dg-error "declared as function returning a function" }
};
struct C
{
  C ();
  C (const C &)();	// { dg-error "declared as function returning a function" }
};

void
foo ()
{
  A a;
  B b;
  C c;
  #pragma omp parallel firstprivate (a)
    ;
  #pragma omp parallel private (b)
    ;
  #pragma omp parallel firstprivate (c)
    ;
}