[clang] [ParserHLSL] Attempt to parse HLSL annotations on Field Decls. (PR #96346)

Joshua Batista via cfe-commits cfe-commits at lists.llvm.org
Fri Jun 21 12:44:24 PDT 2024


================
@@ -0,0 +1,30 @@
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-compute -x hlsl -o - %s -verify
----------------
bob80905 wrote:

There are currently no candidate attributes that have subjects that are field decls other than SV_DispatchThreadID. In other words, SV_DispatchThreadID is the only attribute that appertains to FieldDecls, all other attributes will fail the `diagAppertainsTo` check inside of `tools\clang\include\clang\Sema\AttrParsedAttrImpl.inc`, and that test needs to pass before the parsed attribute can be applied to the decl, and thus appear on the AST.

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


More information about the cfe-commits mailing list