mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 10:03:44 +02:00
Internals: Remove second argument to visitors. No functional change intended.
This commit is contained in:
+67
-67
@@ -635,7 +635,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
}
|
||||
|
||||
// VISITs
|
||||
virtual void visit(AstNetlist* nodep, AstNUser*) {
|
||||
virtual void visit(AstNetlist* nodep) {
|
||||
// Process $unit or other packages
|
||||
// Not needed - dotted references not allowed from inside packages
|
||||
//for (AstNodeModule* nodep = v3Global.rootp()->modulesp(); nodep; nodep=nodep->nextp()->castNodeModule()) {
|
||||
@@ -663,8 +663,8 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
m_curSymp = m_modSymp = NULL;
|
||||
}
|
||||
}
|
||||
virtual void visit(AstTypeTable* nodep, AstNUser*) {}
|
||||
virtual void visit(AstNodeModule* nodep, AstNUser*) {
|
||||
virtual void visit(AstTypeTable* nodep) {}
|
||||
virtual void visit(AstNodeModule* nodep) {
|
||||
// Called on top module from Netlist, other modules from the cell creating them,
|
||||
// and packages
|
||||
UINFO(8," "<<nodep<<endl);
|
||||
@@ -719,11 +719,11 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
// Prep for next
|
||||
m_packagep = NULL;
|
||||
}
|
||||
virtual void visit(AstScope* nodep, AstNUser*) {
|
||||
virtual void visit(AstScope* nodep) {
|
||||
if (!m_statep->forScopeCreation()) v3fatalSrc("Scopes should only exist right after V3Scope");
|
||||
// Ignored. Processed in next step
|
||||
}
|
||||
virtual void visit(AstCell* nodep, AstNUser*) {
|
||||
virtual void visit(AstCell* nodep) {
|
||||
UINFO(5," CELL under "<<m_scope<<" is "<<nodep<<endl);
|
||||
// Process XREFs/etc inside pins
|
||||
nodep->iterateChildren(*this);
|
||||
@@ -760,7 +760,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
m_curSymp = oldCurSymp;
|
||||
m_paramNum = oldParamNum;
|
||||
}
|
||||
virtual void visit(AstCellInline* nodep, AstNUser*) {
|
||||
virtual void visit(AstCellInline* nodep) {
|
||||
UINFO(5," CELLINLINE under "<<m_scope<<" is "<<nodep<<endl);
|
||||
VSymEnt* aboveSymp = m_curSymp;
|
||||
// If baz__DOT__foo__DOT__bar, we need to find baz__DOT__foo and add bar to it.
|
||||
@@ -780,11 +780,11 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
m_statep->insertInline(aboveSymp, m_modSymp, nodep, nodep->name());
|
||||
}
|
||||
}
|
||||
virtual void visit(AstDefParam* nodep, AstNUser*) {
|
||||
virtual void visit(AstDefParam* nodep) {
|
||||
nodep->user1p(m_curSymp);
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstGenerate* nodep, AstNUser*) {
|
||||
virtual void visit(AstGenerate* nodep) {
|
||||
// Begin: ... blocks often replicate under genif/genfor, so simply suppress duplicate checks
|
||||
// See t_gen_forif.v for an example.
|
||||
bool lastInGen = m_inGenerate;
|
||||
@@ -794,7 +794,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
}
|
||||
m_inGenerate = lastInGen;
|
||||
}
|
||||
virtual void visit(AstBegin* nodep, AstNUser*) {
|
||||
virtual void visit(AstBegin* nodep) {
|
||||
UINFO(5," "<<nodep<<endl);
|
||||
// Rename "genblk"s to include a number
|
||||
if (m_statep->forPrimary() && !nodep->user4SetOnce()) {
|
||||
@@ -836,7 +836,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
m_beginp = oldbegin;
|
||||
m_beginNum = oldNum;
|
||||
}
|
||||
virtual void visit(AstNodeFTask* nodep, AstNUser*) {
|
||||
virtual void visit(AstNodeFTask* nodep) {
|
||||
// NodeTask: Remember its name for later resolution
|
||||
UINFO(5," "<<nodep<<endl);
|
||||
if (!m_curSymp || !m_modSymp) nodep->v3fatalSrc("Function/Task not under module??\n");
|
||||
@@ -871,7 +871,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
}
|
||||
m_curSymp = oldCurSymp;
|
||||
}
|
||||
virtual void visit(AstVar* nodep, AstNUser*) {
|
||||
virtual void visit(AstVar* nodep) {
|
||||
// Var: Remember its name for later resolution
|
||||
if (!m_curSymp || !m_modSymp) nodep->v3fatalSrc("Var not under module??\n");
|
||||
nodep->iterateChildren(*this);
|
||||
@@ -955,22 +955,22 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
}
|
||||
}
|
||||
}
|
||||
virtual void visit(AstTypedef* nodep, AstNUser*) {
|
||||
virtual void visit(AstTypedef* nodep) {
|
||||
// Remember its name for later resolution
|
||||
if (!m_curSymp) nodep->v3fatalSrc("Typedef not under module??\n");
|
||||
nodep->iterateChildren(*this);
|
||||
m_statep->insertSym(m_curSymp, nodep->name(), nodep, m_packagep);
|
||||
}
|
||||
virtual void visit(AstParamTypeDType* nodep, AstNUser*) {
|
||||
virtual void visit(AstParamTypeDType* nodep) {
|
||||
if (!m_curSymp) nodep->v3fatalSrc("Parameter type not under module??\n");
|
||||
nodep->iterateChildren(*this);
|
||||
m_statep->insertSym(m_curSymp, nodep->name(), nodep, m_packagep);
|
||||
}
|
||||
virtual void visit(AstCFunc* nodep, AstNUser*) {
|
||||
virtual void visit(AstCFunc* nodep) {
|
||||
// For dotted resolution, ignore all AstVars under functions, otherwise shouldn't exist
|
||||
if (m_statep->forScopeCreation()) nodep->v3fatalSrc("No CFuncs expected in tree yet");
|
||||
}
|
||||
virtual void visit(AstEnumItem* nodep, AstNUser*) {
|
||||
virtual void visit(AstEnumItem* nodep) {
|
||||
// EnumItem: Remember its name for later resolution
|
||||
nodep->iterateChildren(*this);
|
||||
// Find under either a task or the module's vars
|
||||
@@ -1000,7 +1000,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
m_statep->insertSym(m_curSymp, nodep->name(), nodep, m_packagep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstPackageImport* nodep, AstNUser*) {
|
||||
virtual void visit(AstPackageImport* nodep) {
|
||||
UINFO(2," Link: "<<nodep<<endl);
|
||||
VSymEnt* srcp = m_statep->getNodeSym(nodep->packagep());
|
||||
if (nodep->name()!="*") {
|
||||
@@ -1014,7 +1014,7 @@ class LinkDotFindVisitor : public AstNVisitor {
|
||||
// No longer needed, but can't delete until any multi-instantiated modules are expanded
|
||||
}
|
||||
|
||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||
virtual void visit(AstNode* nodep) {
|
||||
// Default: Just iterate
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
@@ -1078,8 +1078,8 @@ private:
|
||||
}
|
||||
|
||||
// VISITs
|
||||
virtual void visit(AstTypeTable* nodep, AstNUser*) {}
|
||||
virtual void visit(AstNodeModule* nodep, AstNUser*) {
|
||||
virtual void visit(AstTypeTable* nodep) {}
|
||||
virtual void visit(AstNodeModule* nodep) {
|
||||
UINFO(5," "<<nodep<<endl);
|
||||
if (nodep->dead() || !nodep->user4()) {
|
||||
UINFO(4,"Mark dead module "<<nodep<<endl);
|
||||
@@ -1094,7 +1094,7 @@ private:
|
||||
m_modp = NULL;
|
||||
}
|
||||
}
|
||||
virtual void visit(AstPin* nodep, AstNUser*) {
|
||||
virtual void visit(AstPin* nodep) {
|
||||
// Pin: Link to submodule's port
|
||||
// Deal with implicit definitions - do before Resolve visitor as may be referenced above declaration
|
||||
if (nodep->exprp() // Else specifically unconnected pin
|
||||
@@ -1102,7 +1102,7 @@ private:
|
||||
pinImplicitExprRecurse(nodep->exprp());
|
||||
}
|
||||
}
|
||||
virtual void visit(AstDefParam* nodep, AstNUser*) {
|
||||
virtual void visit(AstDefParam* nodep) {
|
||||
nodep->iterateChildren(*this);
|
||||
nodep->v3warn(DEFPARAM,"Suggest replace defparam with Verilog 2001 #(."<<nodep->prettyName()<<"(...etc...))");
|
||||
VSymEnt* foundp = m_statep->getNodeSym(nodep)->findIdFallback(nodep->path());
|
||||
@@ -1123,7 +1123,7 @@ private:
|
||||
nodep->unlinkFrBack()->deleteTree(); VL_DANGLING(nodep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstPort* nodep, AstNUser*) {
|
||||
virtual void visit(AstPort* nodep) {
|
||||
// Port: Stash the pin number
|
||||
// Need to set pin numbers after varnames are created
|
||||
// But before we do the final resolution based on names
|
||||
@@ -1142,14 +1142,14 @@ private:
|
||||
// Ports not needed any more
|
||||
nodep->unlinkFrBack()->deleteTree(); VL_DANGLING(nodep);
|
||||
}
|
||||
virtual void visit(AstAssignW* nodep, AstNUser*) {
|
||||
virtual void visit(AstAssignW* nodep) {
|
||||
// Deal with implicit definitions
|
||||
// We used to nodep->allowImplicit() here, but it turns out
|
||||
// normal "assigns" can also make implicit wires. Yuk.
|
||||
pinImplicitExprRecurse(nodep->lhsp());
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstAssignAlias* nodep, AstNUser*) {
|
||||
virtual void visit(AstAssignAlias* nodep) {
|
||||
// tran gates need implicit creation
|
||||
// As VarRefs don't exist in forPrimary, sanity check
|
||||
if (m_statep->forPrimary()) nodep->v3fatalSrc("Assign aliases unexpected pre-dot");
|
||||
@@ -1161,13 +1161,13 @@ private:
|
||||
}
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstImplicit* nodep, AstNUser*) {
|
||||
virtual void visit(AstImplicit* nodep) {
|
||||
// Unsupported gates need implicit creation
|
||||
pinImplicitExprRecurse(nodep);
|
||||
// We're done with implicit gates
|
||||
nodep->unlinkFrBack()->deleteTree(); VL_DANGLING(nodep);
|
||||
}
|
||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||
virtual void visit(AstNode* nodep) {
|
||||
// Default: Just iterate
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
@@ -1197,11 +1197,11 @@ class LinkDotScopeVisitor : public AstNVisitor {
|
||||
int debug() { return LinkDotState::debug(); }
|
||||
|
||||
// VISITs
|
||||
virtual void visit(AstNetlist* nodep, AstNUser* vup) {
|
||||
virtual void visit(AstNetlist* nodep) {
|
||||
// Recurse..., backward as must do packages before using packages
|
||||
nodep->iterateChildrenBackwards(*this);
|
||||
}
|
||||
virtual void visit(AstScope* nodep, AstNUser*) {
|
||||
virtual void visit(AstScope* nodep) {
|
||||
UINFO(8," SCOPE "<<nodep<<endl);
|
||||
if (!m_statep->forScopeCreation()) v3fatalSrc("Scopes should only exist right after V3Scope");
|
||||
// Using the CELL names, we created all hierarchy. We now need to match this Scope
|
||||
@@ -1212,7 +1212,7 @@ class LinkDotScopeVisitor : public AstNVisitor {
|
||||
m_modSymp = NULL;
|
||||
m_scopep = NULL;
|
||||
}
|
||||
virtual void visit(AstVarScope* nodep, AstNUser*) {
|
||||
virtual void visit(AstVarScope* nodep) {
|
||||
if (!nodep->varp()->isFuncLocal()) {
|
||||
VSymEnt* varSymp = m_statep->insertSym(m_modSymp, nodep->varp()->name(), nodep, NULL);
|
||||
if (nodep->varp()->isIfaceRef()
|
||||
@@ -1239,12 +1239,12 @@ class LinkDotScopeVisitor : public AstNVisitor {
|
||||
}
|
||||
}
|
||||
}
|
||||
virtual void visit(AstNodeFTask* nodep, AstNUser*) {
|
||||
virtual void visit(AstNodeFTask* nodep) {
|
||||
VSymEnt* symp = m_statep->insertBlock(m_modSymp, nodep->name(), nodep, NULL);
|
||||
symp->fallbackp(m_modSymp);
|
||||
// No recursion, we don't want to pick up variables
|
||||
}
|
||||
virtual void visit(AstAssignAlias* nodep, AstNUser*) {
|
||||
virtual void visit(AstAssignAlias* nodep) {
|
||||
// Track aliases created by V3Inline; if we get a VARXREF(aliased_from)
|
||||
// we'll need to replace it with a VARXREF(aliased_to)
|
||||
if (debug()>=9) nodep->dumpTree(cout,"-\t\t\t\talias: ");
|
||||
@@ -1254,7 +1254,7 @@ class LinkDotScopeVisitor : public AstNVisitor {
|
||||
fromVscp->user2p(toVscp);
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstAssignVarScope* nodep, AstNUser*) {
|
||||
virtual void visit(AstAssignVarScope* nodep) {
|
||||
UINFO(5,"ASSIGNVARSCOPE "<<nodep<<endl);
|
||||
if (debug()>=9) nodep->dumpTree(cout,"-\t\t\t\tavs: ");
|
||||
VSymEnt* rhsSymp;
|
||||
@@ -1299,10 +1299,10 @@ class LinkDotScopeVisitor : public AstNVisitor {
|
||||
}
|
||||
// For speed, don't recurse things that can't have scope
|
||||
// Note we allow AstNodeStmt's as generates may be under them
|
||||
virtual void visit(AstCell*, AstNUser*) {}
|
||||
virtual void visit(AstVar*, AstNUser*) {}
|
||||
virtual void visit(AstNodeMath*, AstNUser*) {}
|
||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||
virtual void visit(AstCell*) {}
|
||||
virtual void visit(AstVar*) {}
|
||||
virtual void visit(AstNodeMath*) {}
|
||||
virtual void visit(AstNode* nodep) {
|
||||
// Default: Just iterate
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
@@ -1332,7 +1332,7 @@ class LinkDotIfaceVisitor : public AstNVisitor {
|
||||
int debug() { return LinkDotState::debug(); }
|
||||
|
||||
// VISITs
|
||||
virtual void visit(AstModport* nodep, AstNUser*) {
|
||||
virtual void visit(AstModport* nodep) {
|
||||
// Modport: Remember its name for later resolution
|
||||
UINFO(5," fiv: "<<nodep<<endl);
|
||||
VSymEnt* oldCurSymp = m_curSymp;
|
||||
@@ -1344,7 +1344,7 @@ class LinkDotIfaceVisitor : public AstNVisitor {
|
||||
}
|
||||
m_curSymp = oldCurSymp;
|
||||
}
|
||||
virtual void visit(AstModportFTaskRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstModportFTaskRef* nodep) {
|
||||
UINFO(5," fif: "<<nodep<<endl);
|
||||
nodep->iterateChildren(*this);
|
||||
if (nodep->isExport()) nodep->v3error("Unsupported: modport export");
|
||||
@@ -1365,7 +1365,7 @@ class LinkDotIfaceVisitor : public AstNVisitor {
|
||||
nodep->unlinkFrBack(); pushDeletep(nodep); VL_DANGLING(nodep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstModportVarRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstModportVarRef* nodep) {
|
||||
UINFO(5," fiv: "<<nodep<<endl);
|
||||
nodep->iterateChildren(*this);
|
||||
VSymEnt* symp = m_curSymp->findIdFallback(nodep->name());
|
||||
@@ -1388,7 +1388,7 @@ class LinkDotIfaceVisitor : public AstNVisitor {
|
||||
nodep->unlinkFrBack(); pushDeletep(nodep); VL_DANGLING(nodep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||
virtual void visit(AstNode* nodep) {
|
||||
// Default: Just iterate
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
@@ -1524,12 +1524,12 @@ private:
|
||||
}
|
||||
|
||||
// VISITs
|
||||
virtual void visit(AstNetlist* nodep, AstNUser* vup) {
|
||||
virtual void visit(AstNetlist* nodep) {
|
||||
// Recurse..., backward as must do packages before using packages
|
||||
nodep->iterateChildrenBackwards(*this);
|
||||
}
|
||||
virtual void visit(AstTypeTable* nodep, AstNUser*) {}
|
||||
virtual void visit(AstNodeModule* nodep, AstNUser*) {
|
||||
virtual void visit(AstTypeTable* nodep) {}
|
||||
virtual void visit(AstNodeModule* nodep) {
|
||||
if (nodep->dead()) return;
|
||||
checkNoDot(nodep);
|
||||
UINFO(8," "<<nodep<<endl);
|
||||
@@ -1542,7 +1542,7 @@ private:
|
||||
m_modp = NULL;
|
||||
m_ds.m_dotSymp = m_curSymp = m_modSymp = NULL;
|
||||
}
|
||||
virtual void visit(AstScope* nodep, AstNUser*) {
|
||||
virtual void visit(AstScope* nodep) {
|
||||
UINFO(8," "<<nodep<<endl);
|
||||
VSymEnt* oldModSymp = m_modSymp;
|
||||
VSymEnt* oldCurSymp = m_curSymp;
|
||||
@@ -1553,13 +1553,13 @@ private:
|
||||
m_modSymp = oldModSymp;
|
||||
m_curSymp = oldCurSymp;
|
||||
}
|
||||
virtual void visit(AstCellInline* nodep, AstNUser*) {
|
||||
virtual void visit(AstCellInline* nodep) {
|
||||
checkNoDot(nodep);
|
||||
if (m_statep->forScopeCreation()) {
|
||||
nodep->unlinkFrBack(); pushDeletep(nodep); VL_DANGLING(nodep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstCell* nodep, AstNUser*) {
|
||||
virtual void visit(AstCell* nodep) {
|
||||
// Cell: Recurse inside or cleanup not founds
|
||||
checkNoDot(nodep);
|
||||
m_cellp = nodep;
|
||||
@@ -1588,7 +1588,7 @@ private:
|
||||
// Parent module inherits child's publicity
|
||||
// This is done bottom up in the LinkBotupVisitor stage
|
||||
}
|
||||
virtual void visit(AstPin* nodep, AstNUser*) {
|
||||
virtual void visit(AstPin* nodep) {
|
||||
// Pin: Link to submodule's port
|
||||
checkNoDot(nodep);
|
||||
nodep->iterateChildren(*this);
|
||||
@@ -1622,7 +1622,7 @@ private:
|
||||
}
|
||||
// Early return() above when deleted
|
||||
}
|
||||
virtual void visit(AstDot* nodep, AstNUser*) {
|
||||
virtual void visit(AstDot* nodep) {
|
||||
// Legal under a DOT: AstDot, AstParseRef, AstPackageRef, AstNodeSel
|
||||
// also a DOT can be part of an expression, but only above plus AstFTaskRef are legal children
|
||||
// DOT(PACKAGEREF, PARSEREF(text))
|
||||
@@ -1683,7 +1683,7 @@ private:
|
||||
m_ds.m_dotp = lastStates.m_dotp;
|
||||
}
|
||||
}
|
||||
virtual void visit(AstParseRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstParseRef* nodep) {
|
||||
if (nodep->user3SetOnce()) return;
|
||||
UINFO(9," linkPARSEREF "<<m_ds.ascii()<<" n="<<nodep<<endl);
|
||||
// m_curSymp is symbol table of outer expression
|
||||
@@ -1889,7 +1889,7 @@ private:
|
||||
m_ds = lastStates;
|
||||
}
|
||||
}
|
||||
virtual void visit(AstVarRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstVarRef* nodep) {
|
||||
// VarRef: Resolve its reference
|
||||
// ParseRefs are used the first pass (forPrimary) so we shouldn't get can't find
|
||||
// errors here now that we have a VarRef.
|
||||
@@ -1908,7 +1908,7 @@ private:
|
||||
}
|
||||
}
|
||||
}
|
||||
virtual void visit(AstVarXRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstVarXRef* nodep) {
|
||||
// VarRef: Resolve its reference
|
||||
// We always link even if varp() is set, because the module we choose may change
|
||||
// due to creating new modules, flattening, etc.
|
||||
@@ -1973,11 +1973,11 @@ private:
|
||||
}
|
||||
}
|
||||
}
|
||||
virtual void visit(AstEnumItemRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstEnumItemRef* nodep) {
|
||||
// EnumItemRef may be under a dot. Should already be resolved.
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstMethodSel* nodep, AstNUser*) {
|
||||
virtual void visit(AstMethodSel* nodep) {
|
||||
// Created here so should already be resolved.
|
||||
DotStates lastStates = m_ds;
|
||||
{
|
||||
@@ -1986,14 +1986,14 @@ private:
|
||||
}
|
||||
m_ds = lastStates;
|
||||
}
|
||||
virtual void visit(AstVar* nodep, AstNUser*) {
|
||||
virtual void visit(AstVar* nodep) {
|
||||
checkNoDot(nodep);
|
||||
nodep->iterateChildren(*this);
|
||||
if (m_statep->forPrimary() && nodep->isIO() && !m_ftaskp && !nodep->user4()) {
|
||||
nodep->v3error("Input/output/inout does not appear in port list: "<<nodep->prettyName());
|
||||
}
|
||||
}
|
||||
virtual void visit(AstNodeFTaskRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstNodeFTaskRef* nodep) {
|
||||
if (nodep->user3SetOnce()) return;
|
||||
UINFO(8," "<<nodep<<endl);
|
||||
if (m_ds.m_dotp && m_ds.m_dotPos == DP_PACKAGE) {
|
||||
@@ -2084,7 +2084,7 @@ private:
|
||||
}
|
||||
m_ds = lastStates;
|
||||
}
|
||||
virtual void visit(AstSelBit* nodep, AstNUser*) {
|
||||
virtual void visit(AstSelBit* nodep) {
|
||||
if (nodep->user3SetOnce()) return;
|
||||
nodep->lhsp()->iterateAndNext(*this);
|
||||
if (m_ds.m_dotPos == DP_SCOPE) { // Already under dot, so this is {modulepart} DOT {modulepart}
|
||||
@@ -2108,7 +2108,7 @@ private:
|
||||
nodep->replaceWith(newp); pushDeletep(nodep); VL_DANGLING(nodep);
|
||||
}
|
||||
}
|
||||
virtual void visit(AstNodePreSel* nodep, AstNUser*) {
|
||||
virtual void visit(AstNodePreSel* nodep) {
|
||||
// Excludes simple AstSelBit, see above
|
||||
if (nodep->user3SetOnce()) return;
|
||||
if (m_ds.m_dotPos == DP_SCOPE) { // Already under dot, so this is {modulepart} DOT {modulepart}
|
||||
@@ -2126,11 +2126,11 @@ private:
|
||||
}
|
||||
m_ds = lastStates;
|
||||
}
|
||||
virtual void visit(AstMemberSel* nodep, AstNUser*) {
|
||||
virtual void visit(AstMemberSel* nodep) {
|
||||
// checkNoDot not appropriate, can be under a dot
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstBegin* nodep, AstNUser*) {
|
||||
virtual void visit(AstBegin* nodep) {
|
||||
UINFO(5," "<<nodep<<endl);
|
||||
checkNoDot(nodep);
|
||||
VSymEnt* oldCurSymp = m_curSymp;
|
||||
@@ -2142,7 +2142,7 @@ private:
|
||||
m_ds.m_dotSymp = m_curSymp = oldCurSymp;
|
||||
UINFO(5," cur=se"<<(void*)m_curSymp<<endl);
|
||||
}
|
||||
virtual void visit(AstNodeFTask* nodep, AstNUser*) {
|
||||
virtual void visit(AstNodeFTask* nodep) {
|
||||
UINFO(5," "<<nodep<<endl);
|
||||
checkNoDot(nodep);
|
||||
VSymEnt* oldCurSymp = m_curSymp;
|
||||
@@ -2154,7 +2154,7 @@ private:
|
||||
m_ds.m_dotSymp = m_curSymp = oldCurSymp;
|
||||
m_ftaskp = NULL;
|
||||
}
|
||||
virtual void visit(AstRefDType* nodep, AstNUser*) {
|
||||
virtual void visit(AstRefDType* nodep) {
|
||||
// Resolve its reference
|
||||
if (nodep->user3SetOnce()) return;
|
||||
if (m_ds.m_dotp && m_ds.m_dotPos == DP_PACKAGE) {
|
||||
@@ -2187,7 +2187,7 @@ private:
|
||||
}
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstDpiExport* nodep, AstNUser*) {
|
||||
virtual void visit(AstDpiExport* nodep) {
|
||||
// AstDpiExport: Make sure the function referenced exists, then dump it
|
||||
nodep->iterateChildren(*this);
|
||||
checkNoDot(nodep);
|
||||
@@ -2202,25 +2202,25 @@ private:
|
||||
}
|
||||
nodep->unlinkFrBack()->deleteTree(); VL_DANGLING(nodep);
|
||||
}
|
||||
virtual void visit(AstPackageImport* nodep, AstNUser*) {
|
||||
virtual void visit(AstPackageImport* nodep) {
|
||||
// No longer needed
|
||||
checkNoDot(nodep);
|
||||
nodep->unlinkFrBack()->deleteTree(); VL_DANGLING(nodep);
|
||||
}
|
||||
virtual void visit(AstCellRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstCellRef* nodep) {
|
||||
UINFO(5," AstCellRef: "<<nodep<<" "<<m_ds.ascii()<<endl);
|
||||
nodep->iterateChildren(*this);
|
||||
}
|
||||
virtual void visit(AstCellArrayRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstCellArrayRef* nodep) {
|
||||
UINFO(5," AstCellArrayRef: "<<nodep<<" "<<m_ds.ascii()<<endl);
|
||||
// Expression already iterated
|
||||
}
|
||||
virtual void visit(AstUnlinkedRef* nodep, AstNUser*) {
|
||||
virtual void visit(AstUnlinkedRef* nodep) {
|
||||
UINFO(5," AstCellArrayRef: "<<nodep<<" "<<m_ds.ascii()<<endl);
|
||||
// No need to iterate, if we have a UnlinkedVarXRef, we're already done
|
||||
}
|
||||
|
||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||
virtual void visit(AstNode* nodep) {
|
||||
// Default: Just iterate
|
||||
checkNoDot(nodep);
|
||||
nodep->iterateChildren(*this);
|
||||
|
||||
Reference in New Issue
Block a user