mirror of
https://github.com/verilator/verilator.git
synced 2025-01-06 06:37:45 +00:00
Internals: Rename some V3LinkDot variables. No functional change.
This commit is contained in:
parent
0d67caff77
commit
2c84b37bf7
@ -2246,9 +2246,9 @@ private:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
void importSymbolsFromExtended(AstClass* const nodep, AstClassExtends* const cextp) {
|
void importSymbolsFromExtended(AstClass* const nodep, AstClassExtends* const cextp) {
|
||||||
AstClass* const classp = cextp->classp();
|
AstClass* const baseClassp = cextp->classp();
|
||||||
VSymEnt* const srcp = m_statep->getNodeSym(classp);
|
VSymEnt* const srcp = m_statep->getNodeSym(baseClassp);
|
||||||
if (classp->isInterfaceClass()) importImplementsClass(nodep, srcp, classp);
|
if (baseClassp->isInterfaceClass()) importImplementsClass(nodep, srcp, baseClassp);
|
||||||
if (!cextp->isImplements()) m_curSymp->importFromClass(m_statep->symsp(), srcp);
|
if (!cextp->isImplements()) m_curSymp->importFromClass(m_statep->symsp(), srcp);
|
||||||
}
|
}
|
||||||
bool checkPinRef(AstPin* pinp, VVarType refVarType) {
|
bool checkPinRef(AstPin* pinp, VVarType refVarType) {
|
||||||
@ -2445,9 +2445,9 @@ private:
|
|||||||
} else {
|
} else {
|
||||||
const auto cextp = classp->extendsp();
|
const auto cextp = classp->extendsp();
|
||||||
UASSERT_OBJ(cextp, nodep, "Bad super extends link");
|
UASSERT_OBJ(cextp, nodep, "Bad super extends link");
|
||||||
const auto sclassp = cextp->classp();
|
const auto baseClassp = cextp->classp();
|
||||||
UASSERT_OBJ(sclassp, nodep, "Bad superclass");
|
UASSERT_OBJ(baseClassp, nodep, "Bad superclass");
|
||||||
m_ds.m_dotSymp = m_statep->getNodeSym(sclassp);
|
m_ds.m_dotSymp = m_statep->getNodeSym(baseClassp);
|
||||||
UINFO(8, " super. " << m_ds.ascii() << endl);
|
UINFO(8, " super. " << m_ds.ascii() << endl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2896,15 +2896,16 @@ private:
|
|||||||
"class reference parameter not removed by V3Param");
|
"class reference parameter not removed by V3Param");
|
||||||
VL_RESTORER(m_ds);
|
VL_RESTORER(m_ds);
|
||||||
VL_RESTORER(m_pinSymp);
|
VL_RESTORER(m_pinSymp);
|
||||||
{
|
|
||||||
// ClassRef's have pins, so track
|
// ClassRef's have pins, so track
|
||||||
if (nodep->classOrPackagep()) {
|
if (nodep->classOrPackagep()) {
|
||||||
m_pinSymp = m_statep->getNodeSym(nodep->classOrPackagep());
|
m_pinSymp = m_statep->getNodeSym(nodep->classOrPackagep());
|
||||||
}
|
|
||||||
m_ds.init(m_curSymp);
|
|
||||||
UINFO(4, "(Backto) Link ClassOrPackageRef: " << nodep << endl);
|
|
||||||
iterateChildren(nodep);
|
|
||||||
}
|
}
|
||||||
|
m_ds.init(m_curSymp);
|
||||||
|
UINFO(4, "(Backto) Link ClassOrPackageRef: " << nodep << endl);
|
||||||
|
|
||||||
|
iterateChildren(nodep);
|
||||||
|
|
||||||
AstClass* const refClassp = VN_CAST(nodep->classOrPackagep(), Class);
|
AstClass* const refClassp = VN_CAST(nodep->classOrPackagep(), Class);
|
||||||
AstClass* const modClassp = VN_CAST(m_modp, Class);
|
AstClass* const modClassp = VN_CAST(m_modp, Class);
|
||||||
if (m_statep->forPrimary() && refClassp && !nodep->paramsp()
|
if (m_statep->forPrimary() && refClassp && !nodep->paramsp()
|
||||||
@ -3506,26 +3507,26 @@ private:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (AstClass* const classp = cextp->classOrNullp()) {
|
if (AstClass* const baseClassp = cextp->classOrNullp()) {
|
||||||
// Already converted. Update symbol table to link unlinked members.
|
// Already converted. Update symbol table to link unlinked members.
|
||||||
// Base class has to be visited in a case if its extends statement
|
// Base class has to be visited in a case if its extends statement
|
||||||
// needs to be handled. Recursive inheritance was already checked.
|
// needs to be handled. Recursive inheritance was already checked.
|
||||||
if (classp == nodep) {
|
if (baseClassp == nodep) {
|
||||||
cextp->v3error("Attempting to extend class " << nodep->prettyNameQ()
|
cextp->v3error("Attempting to extend class " << nodep->prettyNameQ()
|
||||||
<< " from itself");
|
<< " from itself");
|
||||||
} else if (cextp->isImplements() && !classp->isInterfaceClass()) {
|
} else if (cextp->isImplements() && !baseClassp->isInterfaceClass()) {
|
||||||
cextp->v3error("Attempting to implement from non-interface class "
|
cextp->v3error("Attempting to implement from non-interface class "
|
||||||
<< classp->prettyNameQ() << '\n'
|
<< baseClassp->prettyNameQ() << '\n'
|
||||||
<< "... Suggest use 'extends'");
|
<< "... Suggest use 'extends'");
|
||||||
} else if (!cextp->isImplements() && !nodep->isInterfaceClass()
|
} else if (!cextp->isImplements() && !nodep->isInterfaceClass()
|
||||||
&& classp->isInterfaceClass()) {
|
&& baseClassp->isInterfaceClass()) {
|
||||||
cextp->v3error("Attempting to extend from interface class "
|
cextp->v3error("Attempting to extend from interface class "
|
||||||
<< classp->prettyNameQ() << '\n'
|
<< baseClassp->prettyNameQ() << '\n'
|
||||||
<< "... Suggest use 'implements'");
|
<< "... Suggest use 'implements'");
|
||||||
}
|
}
|
||||||
classp->isExtended(true);
|
baseClassp->isExtended(true);
|
||||||
nodep->isExtended(true);
|
nodep->isExtended(true);
|
||||||
iterate(classp);
|
iterate(baseClassp);
|
||||||
importSymbolsFromExtended(nodep, cextp);
|
importSymbolsFromExtended(nodep, cextp);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@ -3742,6 +3743,7 @@ void V3LinkDot::linkDotGuts(AstNetlist* rootp, VLinkDotStep step) {
|
|||||||
state.computeScopeAliases();
|
state.computeScopeAliases();
|
||||||
state.dumpSelf();
|
state.dumpSelf();
|
||||||
{ LinkDotResolveVisitor{rootp, &state}; }
|
{ LinkDotResolveVisitor{rootp, &state}; }
|
||||||
|
state.dumpSelf();
|
||||||
}
|
}
|
||||||
|
|
||||||
void V3LinkDot::linkDotPrimary(AstNetlist* nodep) {
|
void V3LinkDot::linkDotPrimary(AstNetlist* nodep) {
|
||||||
|
Loading…
Reference in New Issue
Block a user