[cfe-dev] vector constructors

Jochen Wilhelmy j.wilhelmy at arcor.de
Tue Mar 16 14:00:07 PDT 2010


> This works for me:
>
> $ cat t.c
> void foo() {
>   vector float x;
>   x = (vector float)(1,2,3,4);
> }
> $ clang -cc1 t.c -fsyntax-only -faltivec
>
>
>   
Yes I know that this works. It's the c-like extension of the
cast operator to vectors, but in contrast I'd like to have
a c++-like extension of the function style cast:

int(1)
int4(1, 2, 3, 4)


-Jochen




More information about the cfe-dev mailing list