Dont mark AstVar as class member when defined in SelLoopVars

Signed-off-by: Pawel Kojma <pkojma@internships.antmicro.com>
This commit is contained in:
Pawel Kojma 2026-02-11 11:10:55 +01:00
parent ae135d8fdd
commit d352fa5abf
1 changed files with 1 additions and 1 deletions

View File

@ -120,7 +120,7 @@ class LinkResolveVisitor final : public VNVisitor {
}
void visit(AstVar* nodep) override {
iterateChildren(nodep);
if (m_classp && !nodep->isParam()) nodep->varType(VVarType::MEMBER);
if (m_classp && !nodep->isParam() && !VN_IS(nodep->backp(), SelLoopVars)) nodep->varType(VVarType::MEMBER);
if (m_ftaskp) nodep->funcLocal(true);
if (nodep->isSigModPublic()) {
nodep->sigModPublic(false); // We're done with this attribute