[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

Chris B via cfe-commits cfe-commits at lists.llvm.org
Tue Feb 11 09:27:08 PST 2025


================
@@ -1017,4 +1017,15 @@ Error<"'#pragma unsafe_buffer_usage' was not ended">;
 
 def err_pp_pragma_unsafe_buffer_usage_syntax :
 Error<"expected 'begin' or 'end'">;
+
+// HLSL Root Signature Lexing Errors
+let CategoryName = "Root Signature Lexical Issue" in {
+  def err_hlsl_expected_number_literal: Error<"expected numberic literal">;
+  def err_hlsl_number_literal_overflow :
+    Error<"integer literal is too large to be represented in any %select{signed |}0 integer type">;
----------------
llvm-beanz wrote:

I know I suggested matching the language in the other clang diagnostics, but for root signatures these are required to be 32-bit types, not _any_ integer type.
```suggestion
    Error<"integer literal is too large to be represented in 32-bit %select{signed |}0 integer type">;
```

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


More information about the cfe-commits mailing list