diff options
author | Mike Rice <michael.p.rice@intel.com> | 2022-05-24 13:57:41 -0700 |
---|---|---|
committer | Mike Rice <michael.p.rice@intel.com> | 2022-05-25 10:34:07 -0700 |
commit | ba3f85390bde10eab1cbdb68f744b8f5ab31859b (patch) | |
tree | 052bef4133096e760df658a9a41122a2d7bdf547 /clang/lib/Sema/Sema.cpp | |
parent | 8a1984c25e2c982a9388c14bdaf99bdcd3e26bd4 (diff) | |
download | llvm-ba3f85390bde10eab1cbdb68f744b8f5ab31859b.zip llvm-ba3f85390bde10eab1cbdb68f744b8f5ab31859b.tar.gz llvm-ba3f85390bde10eab1cbdb68f744b8f5ab31859b.tar.bz2 |
[OpenMP] Add diagnostic for unterminated 'omp [begin] declare target'
Warns when end-of-file is reached without seeing all matching
'omp end declare target' directives. The diagnostic shows the
location of the related begin directive.
Differential Revision: https://reviews.llvm.org/D126331
Diffstat (limited to 'clang/lib/Sema/Sema.cpp')
-rw-r--r-- | clang/lib/Sema/Sema.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Sema/Sema.cpp b/clang/lib/Sema/Sema.cpp index ce104f3..ad2cb62 100644 --- a/clang/lib/Sema/Sema.cpp +++ b/clang/lib/Sema/Sema.cpp @@ -1157,6 +1157,7 @@ void Sema::ActOnEndOfTranslationUnit() { DiagnoseUnterminatedPragmaAlignPack(); DiagnoseUnterminatedPragmaAttribute(); + DiagnoseUnterminatedOpenMPDeclareTarget(); // All delayed member exception specs should be checked or we end up accepting // incompatible declarations. |