aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM with a small nit
================ Comment at: clang/lib/Sema/SemaDecl.cpp:13453-13466 + if (!VDeclType->isDependentType() && + Context.getAsIncompleteArrayType(VDeclType)) { + if (Init && !Init->getType().isNull() && + !Init->getType()->isDependentType()) { + if (Context.getAsIncompleteArrayType(Init->getType())) { + // Bail out if it is not possible to deduce array size from the + // initializer. ---------------- We can cram everything into one predicate; but this is largely intended to rearrange the logic so we're checking the cheap conditions before trying to call `getAsIncompleteArrayType` twice. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158615/new/ https://reviews.llvm.org/D158615 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits