I\'ve tried playing with clang\'s extended vectors. The ternary operator is supposed to work, but it is not working for me. Example:
int main() { using int4 =
This works in a pinch:
auto const diff = a-b; auto const ra( - (diff!=zero) * a - (diff==zero) *b);
I guess this is a bug in the compiler, or in the documentation you linked.