Fix static function not found from parameterized extends class (#7204) (#7208)

This commit is contained in:
em2machine
2026-03-06 16:23:02 -05:00
committed by GitHub
parent efa53189ea
commit bef5c1f475
3 changed files with 76 additions and 0 deletions
+8
View File
@@ -5008,6 +5008,14 @@ class LinkDotResolveVisitor final : public VNVisitor {
// symbols
return;
}
if (AstClass* const targetClassp = VN_CAST(dotSymp->nodep(), Class)) {
if (m_extendsParam.count(targetClassp)) {
// Target class has parameterized extends not yet resolved.
// Its inherited symbols (e.g. static functions from the base class)
// aren't imported yet - defer to linkDotParamed.
return;
}
}
VSymEnt* const foundp
= m_statep->findSymPrefixed(dotSymp, nodep->name(), baddot, first);