Skip to content

Commit c710d0c

Browse files
committed
Keep same error for 2.0
1 parent 2f73a09 commit c710d0c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

patches/clang/0006-OpenCL-3.0-support.patch

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
From f68c4d91ae0ecca08932de502054d1e89cdf033f Mon Sep 17 00:00:00 2001
1+
From 6dd990a8258c0f46b0202492624770b57c0cca12 Mon Sep 17 00:00:00 2001
22
From: Anton Zabaznov <[email protected]>
33
Date: Thu, 24 Sep 2020 00:12:24 +0300
44
Subject: [PATCH] OpenCL 3.0 support
@@ -6967,15 +6967,15 @@ index 7ddf2e88b7..8105b799e0 100644
69676967
<< Scope << "global or constant";
69686968
else
69696969
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp
6970-
index c4c3598ee7..ce98cbc002 100644
6970+
index c4c3598ee7..8e56a1f4f0 100644
69716971
--- a/lib/Sema/SemaDeclAttr.cpp
69726972
+++ b/lib/Sema/SemaDeclAttr.cpp
69736973
@@ -6112,7 +6112,7 @@ static void handleInternalLinkageAttr(Sema &S, Decl *D, const ParsedAttr &AL) {
69746974
}
69756975

69766976
static void handleOpenCLNoSVMAttr(Sema &S, Decl *D, const ParsedAttr &AL) {
69776977
- if (S.LangOpts.OpenCLVersion != 200)
6978-
+ if (S.LangOpts.OpenCLVersion <= 200)
6978+
+ if (S.LangOpts.OpenCLVersion < 200)
69796979
S.Diag(AL.getLoc(), diag::err_attribute_requires_opencl_version)
69806980
<< AL << "2.0" << 0;
69816981
else

0 commit comments

Comments
 (0)