Fix tracing class parameters (#5014).

This commit is contained in:
Wilson Snyder
2024-03-27 20:07:46 -04:00
parent 0114cb67ca
commit 28b9216f8a
7 changed files with 100 additions and 7 deletions
+1 -1
View File
@@ -158,7 +158,7 @@ class ClassVisitor final : public VNVisitor {
// have a pointer to it yet
m_toScopeMoves.emplace_back(nodep, m_packageScopep);
}
if (!m_ftaskp && nodep->lifetime().isStatic()) {
if (!m_ftaskp && (nodep->lifetime().isStatic() || nodep->isParam())) {
m_toPackageMoves.emplace_back(nodep, m_classPackagep);
// We're really moving the VarScope but we might not
// have a pointer to it yet