diff options
author | Alexey Bataev <a.bataev@hotmail.com> | 2019-02-21 15:51:30 +0000 |
---|---|---|
committer | Alexey Bataev <a.bataev@hotmail.com> | 2019-02-21 15:51:30 +0000 |
commit | 266e803a096929578f51b6ea3a0e4cad87a57cf7 (patch) | |
tree | 7a18a99dc23924a9be1768aab2ce8bc63763303f /lib/Sema/SemaExprCXX.cpp | |
parent | fd5894c8584d9ec141dba7984315e439a59088f2 (diff) |
[CUDA]Delayed diagnostics for the asm instructions.
Summary:
Adapted targetDiag for the CUDA and used for the delayed diagnostics in
asm constructs. Works for both host and device compilation sides.
Reviewers: tra, jlebar
Subscribers: jdoerfert, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D58463
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@354593 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExprCXX.cpp')
-rw-r--r-- | lib/Sema/SemaExprCXX.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp index fe1676abb9..512e256d45 100644 --- a/lib/Sema/SemaExprCXX.cpp +++ b/lib/Sema/SemaExprCXX.cpp @@ -750,7 +750,7 @@ ExprResult Sema::BuildCXXThrow(SourceLocation OpLoc, Expr *Ex, bool IsThrownVarInScope) { // Don't report an error if 'throw' is used in system headers. if (!getLangOpts().CXXExceptions && - !getSourceManager().isInSystemHeader(OpLoc)) { + !getSourceManager().isInSystemHeader(OpLoc) && !getLangOpts().CUDA) { // Delay error emission for the OpenMP device code. targetDiag(OpLoc, diag::err_exceptions_disabled) << "throw"; } |