https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104913
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- We also warn e.g. in void foo () { int x; #pragma omp task firstprivate(x) ; } case. To some extent at least for data sharing and most other OpenMP clauses the data sharing isn't really a kind of use, the variable there is still unused. depend clause is a border line, it also isn't either setter nor use and such use is questionable, on the other side under the hood it is taking the address of the variable and using that for the dependency purposes, so it is some kind of a light use. On the other side, e.g. the C FE build_external_ref function handles various other tasks, like -Wdeprecated or setting DECL_NONLOCAL, so perhaps we want to do it for all OpenMP clauses somewhere. Similarly, C++ mark_used can even instantiate stuff etc.