================
@@ -9688,6 +9688,28 @@ static void assignInheritanceModel(Sema &S,
CXXRecordDecl *RD) {
}
}
+/// Return the (possibly nested) constant array type in \p T whose size cannot
+/// be represented, if any. BuildArrayType can only check the element count if
+/// the element type is still incomplete when the array type is formed.
+static const ConstantArrayType *findArrayTypeTooLarge(const ASTContext
&Context,
+ QualType T) {
+ const auto *CAT = dyn_cast<ConstantArrayType>(T.getCanonicalType());
----------------
erichkeane wrote:
You can't do dyn_cast here. you have to use `getAsConstantArrayType`.
https://github.com/llvm/llvm-project/pull/219817
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits