of the array type itself.
This fixes a bug found by inspection that was introduced in r353459. I
don't have a test case for this since we don't yet have types that would
make the containing C struct non-trivial to copy/move but wouldn't make
it non-trivial to default-initialize or destruct.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@353556
91177308-0d34-0410-b5e6-
96231b3b80d8
bool visitWithKind(QualType::PrimitiveCopyKind PCK, QualType QT) {
if (const auto *AT = this->Ctx.getAsArrayType(QT))
- return this->asDerived().visit(QualType(AT, 0));
+ return this->asDerived().visit(Ctx.getBaseElementType(AT));
return Super::visitWithKind(PCK, QT);
}