We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 10a06e3 commit ac99f5aCopy full SHA for ac99f5a
clang/lib/Sema/SemaHLSL.cpp
@@ -3630,10 +3630,7 @@ void SemaHLSL::ActOnVariableDeclarator(VarDecl *VD) {
3630
if (VD->getType()->isHLSLIntangibleType())
3631
collectResourceBindingsOnVarDecl(VD);
3632
3633
- const Type *VarType = VD->getType().getTypePtr();
3634
- while (VarType->isArrayType())
3635
- VarType = VarType->getArrayElementTypeNoTypeQual();
3636
- if (VarType->isHLSLResourceRecord() ||
+ if (isResourceRecordTypeOrArrayOf(VD) ||
3637
VD->hasAttr<HLSLVkConstantIdAttr>()) {
3638
// Make the variable for resources static. The global externally visible
3639
// storage is accessed through the handle, which is a member. The variable
0 commit comments