[flang-commits] [PATCH] D123237: [flang] Fix LBOUND() folding for constant arrays
Jean Perier via Phabricator via flang-commits
flang-commits at lists.llvm.org
Tue Apr 19 05:22:19 PDT 2022
jeanPerier accepted this revision.
jeanPerier added a comment.
This revision is now accepted and ready to land.
LGTM aside of the two style nits.
================
Comment at: flang/lib/Evaluate/fold-integer.cpp:24
+ // As rank-dim array
+ const int rank = GetRank(bounds);
+ std::vector<Scalar<T>> packed(rank);
----------------
Prefer `{}` init instead of `=` init in semantics code.
================
Comment at: flang/lib/Evaluate/fold-integer.cpp:115
+ const ConstantSubscripts bounds =
+ GetConstantArrayLboundHelper{dim}.GetLbound(*array);
+ return PackageConstantBounds<T>(std::move(bounds), dim.has_value());
----------------
Prefer `{}` init instead of `=` init in semantics code.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D123237/new/
https://reviews.llvm.org/D123237
More information about the flang-commits
mailing list