Skip to content

Commit 8cc6e9e

Browse files
committed
[SYCL][Sema] Disable depreacate warning for sycl
Workaround to disable new deprecated warning for sycl before we can clean up and re-enable it later.
1 parent 8d27c2c commit 8cc6e9e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/lib/Sema/SemaAvailability.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -544,7 +544,8 @@ static void DoEmitAvailabilityWarning(Sema &S, AvailabilityResult K,
544544
S.getTopMostPointOfInstantiation(ReferringDecl);
545545
bool ShouldAllowWarningInSystemHeader =
546546
InstantiationLoc != Loc &&
547-
!S.getSourceManager().isInSystemHeader(InstantiationLoc);
547+
!S.getSourceManager().isInSystemHeader(InstantiationLoc) &&
548+
!S.getLangOpts().SYCLIsDevice && !S.getLangOpts().SYCLIsHost;
548549
struct AllowWarningInSystemHeaders {
549550
AllowWarningInSystemHeaders(DiagnosticsEngine &E,
550551
bool AllowWarningInSystemHeaders)

0 commit comments

Comments
 (0)