Skip to content

Commit c58a3fd

Browse files
[OpenCL C] lift restriction on l-val vec literal. (#515)
OpenCL C has disallowed vector literals to be l-values. However, similar functionality in C99 is allowed for the compound literals. This therefore prevented implementing the restriction in upstream tooling, therefore it is decided to change to an implementation defined behavior instead of restricting the functionality.
1 parent ba36e24 commit c58a3fd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

OpenCL_C.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -717,7 +717,7 @@ Vector literals can be used to create vectors from a list of scalars,
717717
vectors or a mixture thereof.
718718
A vector literal can be used either as a vector initializer or as a primary
719719
expression.
720-
A vector literal cannot be used as an l-value.
720+
Whether a vector literal can be used as an l-value is implementation-defined.
721721

722722
A vector literal is written as a parenthesized vector type followed by a
723723
parenthesized comma delimited list of parameters.

0 commit comments

Comments
 (0)