[PATCH] D87151: [flang] Fix assert on constant folding of extended types
Peter Klausler via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 4 14:23:56 PDT 2020
klausler added inline comments.
================
Comment at: flang/lib/Evaluate/expression.cpp:222
+ auto parentIter{parentDetails->componentNames().begin()};
+ for (const auto &childIter : values_) {
+ if (parentIter == parentDetails->componentNames().end()) {
----------------
This loop seems to assume that the order of the containing structure constructor's values will be in 1-1 correspondence with the components of the parent constructor without gaps or rearrangement, and that the parent's parent component (if any) will appear only as a single leading component without a need to recurse to collect its components.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D87151/new/
https://reviews.llvm.org/D87151
More information about the llvm-commits
mailing list