This is an archive of the discontinued LLVM Phabricator instance.

[flang] Special handling of ENTRY BIND(C,NAME=...)
ClosedPublic

Authored by klausler on Sep 21 2022, 5:18 PM.

Details

Summary

We apply special symbol table scoping to top-level subroutine
and function names that have interoperable binding names, so
that it's possible to define the same subroutine/function name
more than once at the top level so long as their binding names
are distinct. But we don't use those scoping techniques for
ENTRY statement symbols with interoperable binding names,
which can lead to bogus semantic errors when the same ENTRY
name is defined multiple times with distinct binding names.

Diff Detail

Event Timeline

klausler created this revision.Sep 21 2022, 5:18 PM
Herald added a project: Restricted Project. · View Herald Transcript
Herald added a subscriber: jdoerfert. · View Herald Transcript
klausler requested review of this revision.Sep 21 2022, 5:18 PM
PeteSteinfeld accepted this revision.Sep 22 2022, 6:45 AM

Apart from the extra empty statement in resolve-names.cpp, all builds and tests correctly and looks good.

flang/lib/Semantics/resolve-names.cpp
3512

This looks spurious.

This revision is now accepted and ready to land.Sep 22 2022, 6:45 AM
klausler updated this revision to Diff 462195.Sep 22 2022, 9:05 AM

Remove spurious empty statement.

This revision was automatically updated to reflect the committed changes.