[all-commits] [llvm/llvm-project] 7a4874: [Flang] Fix statement-function shadowing to avoid ...
CHANDRA GHALE via All-commits
all-commits at lists.llvm.org
Wed Apr 15 06:12:11 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 7a48740f3c122a9e45172f609ef22335962248e3
https://github.com/llvm/llvm-project/commit/7a48740f3c122a9e45172f609ef22335962248e3
Author: CHANDRA GHALE <chandra.nitdgp at gmail.com>
Date: 2026-04-15 (Wed, 15 Apr 2026)
Changed paths:
M flang/lib/Semantics/resolve-names.cpp
M flang/test/Semantics/stmt-func02.f90
A flang/test/Semantics/stmt-func03.f90
Log Message:
-----------
[Flang] Fix statement-function shadowing to avoid false unresolved-symbol internal error (#189360)
When a statement function shadows a host-associated internal procedure
name, HandleStmtFunction creates a local symbol but leaves name.symbol
pointing to the host SubprogramNameDetails.
Because of that stale pointer, AnalyzeStmtFunctionStmt exits early (it
expects SubprogramDetails), so the RHS is never resolved and flang emits
a false `internal error: "Internal: no symbol found".` Clearing
name.symbol after creating the local shadow symbol lets it re-resolve
correctly and fixes the issue.
---------
Co-authored-by: Chandra Ghale <ghale at pe34genoa.hpc.amslabs.hpecorp.net>
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list