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

Chris B via cfe-commits cfe-commits at lists.llvm.org
Sun Feb 9 13:10:13 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_invalid_number_literal:
+    Error<"expected number literal is not a supported number literal of unsigned integer or integer">;
+  def err_hlsl_number_literal_overflow :
+    Error<"provided %select{unsigned integer|signed integer}0 literal '%1' that overflows the maximum of 32 bits">;
----------------
llvm-beanz wrote:

The context of this error is really similar to an existing clang error: err_integer_literal_too_large. I don't think it makes sense to share the message, but we should at least use similar language.

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


More information about the cfe-commits mailing list