]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/g++.dg/gomp/pr33372-3.C
f0a1910bf42ea8ad35468a2f951ffe4c92750c23
[thirdparty/gcc.git] / gcc / testsuite / g++.dg / gomp / pr33372-3.C
1 // PR c++/33372
2 // { dg-do compile }
3 // { dg-options "-fopenmp" }
4
5 template <typename T>
6 void f ()
7 {
8 T n = 6;
9 #pragma omp parallel num_threads(n) // { dg-error "'num_threads' expression must be integral" }
10 ;
11 #pragma omp parallel for schedule(static, n)
12 for (int i = 0; i < 10; i++) // { dg-error "chunk size expression must be integral" }
13 ;
14 }
15
16 void g ()
17 {
18 f<double> ();
19 }