This revision was automatically updated to reflect the committed changes.
Closed by commit rL288126: [OpenCL] Prohibit using reserve_id_t in program
scope. (authored by bader).
Changed prior to commit:
https://reviews.llvm.org/D27099?vs=79508&id=79525#toc
Repository:
rL LLVM
https://reviews
echuraev updated this revision to Diff 79508.
https://reviews.llvm.org/D27099
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaDecl.cpp
test/SemaOpenCL/event_t.cl
test/SemaOpenCL/invalid-clk-events-cl2.0.cl
test/SemaOpenCL/invalid-pipes-cl2.0.cl
Index: test/SemaOpenCL/inv
Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.
LGTM! Thanks! Please, address the small nitpick before committing.
Comment at: lib/Sema/SemaDecl.cpp:5965
+
+// OpenCL 1.2 spec, p6.9 r:
+// The event type cann
echuraev updated this revision to Diff 79372.
echuraev marked 2 inline comments as done.
https://reviews.llvm.org/D27099
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaDecl.cpp
test/SemaOpenCL/event_t.cl
test/SemaOpenCL/invalid-clk-events-cl2.0.cl
test/SemaOpenCL/invalid
Anastasia added inline comments.
Comment at: lib/Sema/SemaDecl.cpp:5924
- DeclContext *OriginalDC = DC;
- bool IsLocalExternDecl = SC == SC_Extern &&
- adjustContextForLocalExternDecl(DC);
+// OpenCL 1.2 spec, p6.9 r:
+// The event type canno
echuraev updated this revision to Diff 79292.
echuraev marked 3 inline comments as done.
https://reviews.llvm.org/D27099
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaDecl.cpp
test/SemaOpenCL/event_t.cl
test/SemaOpenCL/invalid-clk-events-cl2.0.cl
test/SemaOpenCL/invalid
Anastasia added a comment.
Btw, Spec v2.0 s6.9.p seems to mention other types as well!
Comment at: lib/Sema/SemaDecl.cpp:5923
+ if (getLangOpts().OpenCL && (NULL == S->getParent())) {
+if (R->isReserveIDT()) {
- Could we combine with the OpenCL check abo
echuraev created this revision.
echuraev added a reviewer: Anastasia.
echuraev added subscribers: bader, yaxunl, cfe-commits.
https://reviews.llvm.org/D27099
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaDecl.cpp
test/SemaOpenCL/event_t.cl
test/SemaOpenCL/invalid-pipes-cl