[clang] [HLSL] Add a warning for implicit bindings (PR #135909)

Joshua Batista via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 16 13:12:51 PDT 2025


================
@@ -14,6 +14,12 @@ RWBuffer<int> c;
 // No warning - explicit binding.
 RWBuffer<float> d : register(u0);
 
+// No warning - explicit binding.
+RWBuffer<float> dd : register(space1);
----------------
bob80905 wrote:

Shouldn't there be a warning here?
Though the space param is being explicitly bound, the register number within that space is implicitly bound, no?

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


More information about the cfe-commits mailing list