[PATCH] D92970: [flang] Fix bogus message on index-names in the presence of associated entities
Pete Steinfeld via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 9 13:54:26 PST 2020
PeteSteinfeld created this revision.
PeteSteinfeld added reviewers: klausler, tskeith.
Herald added a subscriber: arphaman.
PeteSteinfeld requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
The semantic analysis of index-names of FORALL statements looks up symbols with
the same name as the index-name. This is needed to exclude symbols that are
not objects. But if the symbol found is host-, use-, or construct-associated
with another entity, the check fails.
I fixed this by getting the root symbol of the symbol found and doing the check
on the root symbol. This required creating a non-const version of
"GetAssociationRoot()".
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D92970
Files:
flang/include/flang/Evaluate/tools.h
flang/lib/Evaluate/tools.cpp
flang/lib/Semantics/resolve-names.cpp
flang/test/Semantics/resolve99.f90
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D92970.310652.patch
Type: text/x-patch
Size: 4198 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201209/ae2c363e/attachment.bin>
More information about the llvm-commits
mailing list