[clang] [HLSL] Update Sema Checking Diagnostics for builtins (PR #138429)

Helena Kotas via cfe-commits cfe-commits at lists.llvm.org
Fri May 9 14:08:30 PDT 2025


================
@@ -42,47 +42,47 @@ float2 test_mad_element_type_mismatch(half2 p0, float2 p1) {
 
 float2 test_builtin_mad_float2_splat(float p0, float2 p1) {
   return __builtin_hlsl_mad(p0, p1, p1);
-  // expected-error at -1 {{all arguments to '__builtin_hlsl_mad' must be vectors}}
+  // expected-error at -1 {{arguments are of different types ('double' vs 'float2' (aka 'vector<float, 2>'))}}
----------------
hekota wrote:

This is reporting `double` in the error message while the function argument is `float`, and I see the same thing on lines 50, 55 and 85.

https://github.com/llvm/llvm-project/pull/138429


More information about the cfe-commits mailing list