r369779 - [OpenCL] Renamed value of std flag in C++ mode.
Anastasia Stulova via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 23 10:10:33 PDT 2019
Author: stulova
Date: Fri Aug 23 10:10:33 2019
New Revision: 369779
URL: http://llvm.org/viewvc/llvm-project?rev=369779&view=rev
Log:
[OpenCL] Renamed value of std flag in C++ mode.
Clang should accept -std=clc++ (not -std=c++!) for OpenCL.
This was forgotten in r367008.
Modified:
cfe/trunk/include/clang/Basic/LangStandards.def
cfe/trunk/test/Driver/unknown-std.cl
Modified: cfe/trunk/include/clang/Basic/LangStandards.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/LangStandards.def?rev=369779&r1=369778&r2=369779&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/LangStandards.def (original)
+++ cfe/trunk/include/clang/Basic/LangStandards.def Fri Aug 23 10:10:33 2019
@@ -165,7 +165,7 @@ LANGSTANDARD(opencl12, "cl1.2",
LANGSTANDARD(opencl20, "cl2.0",
OpenCL, "OpenCL 2.0",
LineComment | C99 | Digraphs | HexFloat | OpenCL)
-LANGSTANDARD(openclcpp, "c++",
+LANGSTANDARD(openclcpp, "clc++",
OpenCL, "C++ for OpenCL",
LineComment | CPlusPlus | CPlusPlus11 | CPlusPlus14 | CPlusPlus17 |
Digraphs | HexFloat | OpenCL)
Modified: cfe/trunk/test/Driver/unknown-std.cl
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/unknown-std.cl?rev=369779&r1=369778&r2=369779&view=diff
==============================================================================
--- cfe/trunk/test/Driver/unknown-std.cl (original)
+++ cfe/trunk/test/Driver/unknown-std.cl Fri Aug 23 10:10:33 2019
@@ -10,7 +10,7 @@
// CHECK-NEXT: note: use 'cl1.1' for 'OpenCL 1.1' standard
// CHECK-NEXT: note: use 'cl1.2' for 'OpenCL 1.2' standard
// CHECK-NEXT: note: use 'cl2.0' for 'OpenCL 2.0' standard
-// CHECK-NEXT: note: use 'c++' for 'C++ for OpenCL' standard
+// CHECK-NEXT: note: use 'clc++' for 'C++ for OpenCL' standard
// Make sure that no other output is present.
// CHECK-NOT: {{^.+$}}
More information about the cfe-commits
mailing list