[clang] [HLSL] get inout/out ABI for array parameters working (PR #111047)

Chris B via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 7 13:06:31 PDT 2024


================
@@ -3830,6 +3830,16 @@ QualType ASTContext::getDecayedType(QualType T) const {
   return getDecayedType(T, Decayed);
 }
 
+QualType ASTContext::getConstantArrayFromArrayParameterType(QualType Ty) const {
+  if (Ty->isConstantArrayType() && !Ty->isArrayParameterType())
+    return Ty;
----------------
llvm-beanz wrote:

The name of this method implies that it would be wrong to call this with anything other than an `ArrayParameterType`.

Maybe it makes sense to make this a method on the ArrayParameterType so that you can operate on `this` knowing it is the correct type?

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


More information about the cfe-commits mailing list