https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88988
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2019-01-24 Ever confirmed|0 |1 --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- It ICEs also with template <typename T> struct A { A () : a () { [&] () { #pragma omp parallel firstprivate (a) if (0) ++a; } (); } T a; }; A<int> x; which ought to be valid in OpenMP 5.0 (without if (0) it is racy), not really valid OpenMP 4.5 because mixing C++11 and later futures like lambda here with OpenMP features is undefined. We do compile struct B { B () : b () { [&] () { #pragma omp parallel firstprivate (b) if (0) ++b; } (); } int b; }; B y; though.