[cfe-dev] result of vector comparison

Eli Friedman eli.friedman at gmail.com
Fri Sep 2 09:53:00 PDT 2011


On Fri, Sep 2, 2011 at 3:23 AM, Jochen Wilhelmy <j.wilhelmy at arcor.de> wrote:
> Hi!
>
> I have the following problem:
> I have some functions taking an int vector (of style
> typedef int __attribute__((ext_vector_type(4))) int4)
>
> e.g.
> void foo(int2);
> void foo(int3);
> void foo(int4);
>
> then I do e.g. foo(myFloatVector < 1.0f);
>
> I get errors call to 'foo' is ambiguous. It also does not work if I use
> uint2,3,4 or bool2,3,4.
> So what is the result of the comparison?
> I'm using the 2.9'er release.

There's a known bug in 2.9 (fixed on trunk) that overloading doesn't
work correctly with vectors.

-Eli



More information about the cfe-dev mailing list