[flang-commits] [flang] [Flang] Fix statement-function shadowing to avoid false unresolved-symbol internal error (PR #189360)
CHANDRA GHALE via flang-commits
flang-commits at lists.llvm.org
Wed Apr 15 04:51:27 PDT 2026
================
@@ -4687,6 +4687,10 @@ bool SubprogramVisitor::HandleStmtFunction(const parser::StmtFunctionStmt &x) {
"Name '%s' from host scope should have a type declaration before its local statement function definition"_port_en_US,
name.source);
MakeSymbol(name, Attrs{}, UnknownDetails{});
+ // 'name' may still point to a host-associated SubprogramNameDetails
+ // symbol. Reset it so statement-function processing
+ // re-resolves to the new local SubprogramDetails.
----------------
chandraghale wrote:
Done !!
https://github.com/llvm/llvm-project/pull/189360
More information about the flang-commits
mailing list