[OpenCL] Accept .rgba in OpenCL 3.0
authorSven van Haastregt <sven.vanhaastregt@arm.com>
Mon, 12 Apr 2021 08:30:06 +0000 (09:30 +0100)
committerSven van Haastregt <sven.vanhaastregt@arm.com>
Mon, 12 Apr 2021 08:30:06 +0000 (09:30 +0100)
commit731bf28a6092286dde6972803b35c026e32bd6b1
treef01c3b30e91ed0f6aef2dad47b5efd14a20663e6
parenta655f250fef84795e3e46c0bcb824d7b5fbceec6
[OpenCL] Accept .rgba in OpenCL 3.0

The .rgba vector component accessors are supported in OpenCL C 3.0.

Previously, the diagnostic would check `OpenCLVersion` for version 2.2
(value 220) and report those accessors are an OpenCL 2.2 feature.
However, there is no "OpenCL C version 2.2", so change the check and
diagnostic text to 3.0 only.

A spurious `OpenCLVersion` argument was passed into the diagnostic;
remove that.

Differential Revision: https://reviews.llvm.org/D99969
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaExprMember.cpp
clang/test/SemaOpenCL/ext_vectors.cl