[flang-commits] [flang] [flang] Don't evaluate initializers for arrays with invalid rank (PR #171163)
Eugene Epshteyn via flang-commits
flang-commits at lists.llvm.org
Mon Dec 8 10:08:38 PST 2025
================
@@ -9209,6 +9209,11 @@ bool DeclarationVisitor::CheckNonPointerInitialization(
void DeclarationVisitor::NonPointerInitialization(
const parser::Name &name, const parser::ConstantExpr &constExpr) {
+ // Don't evaluate initializers for arrays with a rank greater than the
----------------
eugeneepshteyn wrote:
Wouldn't it be better to detect that the rank is too large earlier in the symbol declaration and emit an error to the user?
https://github.com/llvm/llvm-project/pull/171163
More information about the flang-commits
mailing list