https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64748
Thomas Schwinge <tschwinge at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2015-02-10 CC| |jakub at gcc dot gnu.org, | |jnorris at gcc dot gnu.org, | |tschwinge at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #1 from Thomas Schwinge <tschwinge at gcc dot gnu.org> --- This also needs to be fixed for C++. I think I based the OpenACC deviceptr code on c_parser_omp_threadprivate -- does that have the same issue then? Note that the C++ front end code for OpenMP threadprivate, gcc/cp/parser.c:cp_parser_omp_threadprivate and gcc/cp/semantics.c:finish_omp_threadprivate is different from the C code, which probably also would be good to unify? I have found the following note in my TODO list, which can then also be verified/addressed at the same time: goto l; l: #pragma acc parallel deviceptr(l) /* { dg-error "'l' is not a pointer variable" } */ ; #pragma acc parallel deviceptr(l[1:3]) /* { dg-error "'l' is not a pointer variable" "" { target *-*-* } 15 } */ /* { dg-error "expected ')' before '\[' token" "" { target *-*-* } 15 } */ ;