[OpenMP] Fix data sharing analysis in nested clause
authorJoel E. Denny <jdenny.ornl@gmail.com>
Wed, 19 Dec 2018 15:59:47 +0000 (15:59 +0000)
committerJoel E. Denny <jdenny.ornl@gmail.com>
Wed, 19 Dec 2018 15:59:47 +0000 (15:59 +0000)
commit0fdf5a9acccef8b5cf21a38bd5fd0496a285fbed
tree32946ee4c06058f4b71fcd1bcdaced0ad2ec6556
parent6c735b02f15e70718d96d70c90ff3ba410e05950
[OpenMP] Fix data sharing analysis in nested clause

Without this patch, clang doesn't complain that X needs explicit data
sharing attributes in the following:

```
 #pragma omp target teams default(none)
 {
   #pragma omp parallel num_threads(X)
     ;
 }
```

However, clang does produce that complaint after the braces are
removed.  With this patch, clang complains in both cases.

Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D55861

llvm-svn: 349635
clang/lib/Sema/SemaOpenMP.cpp
clang/test/OpenMP/target_teams_messages.cpp