Giovanni Mascellani (@giomasce) commented about tests/hlsl/ternary.shader_test:
+[pixel shader]
+uniform float3 a; +uniform float4 b;
+float4 main() : sv_target +{
- return float4(0 ? a : b, 1.0);
+}
+% The condition is more restrictive. Either: +% * the class and dimensions must match exactly; +% * one of the two is scalar; +% * one is a typeN and the other is a type1xN
This is a bit hard to parse for me: * "Condition" is overloaded here: one meaning if the condition (i.e., first) argument to the ternary construct, which I believe to be what you mean; another meaning is the fact that the following is a list of "conditions" that must be satisfied for compilation to succeed; * you mention "two" things, and then "one" and the "other": since the ternary construct deals with three arguments, I'm not sure of what you mean. Are the "two" the type of the first argument and the combined type of the latest two arguments to the ternary construct?