]> granicus.if.org Git - clang/commit
[OpenCL] Restrict swizzle length check to OpenCL mode
authorBruno Cardoso Lopes <bruno.cardoso@gmail.com>
Tue, 17 Oct 2017 17:54:57 +0000 (17:54 +0000)
committerBruno Cardoso Lopes <bruno.cardoso@gmail.com>
Tue, 17 Oct 2017 17:54:57 +0000 (17:54 +0000)
commitba3236375985e92ce121e96172900732967d1e73
treedcad2d61dd84ad30843fadabc4f8c7afcb4f4c2f
parentf78232dcbf734a1c7e42ae60b58c9bbe14b64516
[OpenCL] Restrict swizzle length check to OpenCL mode

Changes behavior introduced in r298369 to only error out on
vector component invalid length access on OpenCL mode.

Differential Revision: https://reviews.llvm.org/D38868

rdar://problem/33568748

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@316016 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaExprMember.cpp
test/Sema/vector_swizzle_length.c [new file with mode: 0644]
test/SemaOpenCL/vector_swizzle_length.cl