@@ -76,37 +76,37 @@ int64_t test_builtin_dot_vec_int16_to_int64_promotion(int64_t2 p0,
7676
7777float test_builtin_dot_float2_splat (float p0, float2 p1) {
7878 return __builtin_hlsl_dot (p0, p1);
79- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
79+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
8080}
8181
8282float test_builtin_dot_float3_splat (float p0, float3 p1) {
8383 return __builtin_hlsl_dot (p0, p1);
84- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
84+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
8585}
8686
8787float test_builtin_dot_float4_splat (float p0, float4 p1) {
8888 return __builtin_hlsl_dot (p0, p1);
89- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
89+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
9090}
9191
9292float test_dot_float2_int_splat (float2 p0, int p1) {
9393 return __builtin_hlsl_dot (p0, p1);
94- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
94+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
9595}
9696
9797float test_dot_float3_int_splat (float3 p0, int p1) {
9898 return __builtin_hlsl_dot (p0, p1);
99- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
99+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
100100}
101101
102102float test_builtin_dot_int_vect_to_float_vec_promotion (int2 p0, float p1) {
103103 return __builtin_hlsl_dot (p0, p1);
104- // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must be vectors }}
104+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type }}
105105}
106106
107107int test_builtin_dot_bool_type_promotion (bool p0, float p1) {
108108 return __builtin_hlsl_dot (p0, p1);
109- // expected-error@-1 {{1st argument must be a vector, integer or floating-point type (was 'bool')}}
109+ // expected-error@-1 {{1st argument must be a scalar or vector of integer or floating-point types (was 'bool')}}
110110}
111111
112112double test_dot_double (double2 p0, double2 p1) {
@@ -120,10 +120,15 @@ double test_dot_double_builtin(double2 p0, double2 p1) {
120120
121121float builtin_bool_to_float_type_promotion ( float p0, bool p1 ) {
122122 return __builtin_hlsl_dot ( p0, p1 );
123- // expected-error@-1 {{are of different types ('float' vs 'bool')}}
123+ // expected-error@-1 {{2nd argument must be a scalar or vector of integer or floating-point types (was 'bool')}}
124124}
125125
126126float builtin_dot_int_to_float_promotion ( float p0, int p1 ) {
127127 return __builtin_hlsl_dot (p0, p1 );
128- // expected-error@-1 {{are of different types ('float' vs 'int')}}
128+ // expected-error@-1 {{all arguments to '__builtin_hlsl_dot' must have the same type}}
129+ }
130+
131+ // should not error
132+ uint builtin_dot_literal_shouldnt_error ( uint4 p0) {
133+ return dot (p0, 1u.xxxx);
129134}
0 commit comments