mirror of
https://github.com/verilator/verilator.git
synced 2026-09-07 18:06:07 +02:00
Internals: Style cleanup. Ignore whitespace if diff. No functional change.
This commit is contained in:
+24
-28
@@ -149,32 +149,30 @@ class ScopeVisitor final : public VNVisitor {
|
||||
VL_RESTORER(m_aboveCellp);
|
||||
VL_RESTORER(m_aboveScopep);
|
||||
VL_RESTORER(m_modp);
|
||||
{
|
||||
m_aboveScopep = m_scopep;
|
||||
m_modp = nodep;
|
||||
m_aboveScopep = m_scopep;
|
||||
m_modp = nodep;
|
||||
|
||||
string scopename;
|
||||
if (!m_aboveScopep) {
|
||||
scopename = "TOP";
|
||||
} else {
|
||||
scopename = m_aboveScopep->name() + "." + nodep->name();
|
||||
}
|
||||
|
||||
UINFO(4, " CLASS AT " << scopename << " " << nodep << endl);
|
||||
AstNode::user1ClearTree();
|
||||
|
||||
const AstNode* const abovep = (m_aboveCellp ? static_cast<AstNode*>(m_aboveCellp)
|
||||
: static_cast<AstNode*>(nodep));
|
||||
m_scopep
|
||||
= new AstScope{abovep->fileline(), m_modp, scopename, m_aboveScopep, m_aboveCellp};
|
||||
m_packageScopes.emplace(nodep, m_scopep);
|
||||
|
||||
// Create scope for the current usage of this cell
|
||||
AstNode::user1ClearTree();
|
||||
nodep->addMembersp(m_scopep);
|
||||
|
||||
iterateChildren(nodep);
|
||||
string scopename;
|
||||
if (!m_aboveScopep) {
|
||||
scopename = "TOP";
|
||||
} else {
|
||||
scopename = m_aboveScopep->name() + "." + nodep->name();
|
||||
}
|
||||
|
||||
UINFO(4, " CLASS AT " << scopename << " " << nodep << endl);
|
||||
AstNode::user1ClearTree();
|
||||
|
||||
const AstNode* const abovep
|
||||
= (m_aboveCellp ? static_cast<AstNode*>(m_aboveCellp) : static_cast<AstNode*>(nodep));
|
||||
m_scopep
|
||||
= new AstScope{abovep->fileline(), m_modp, scopename, m_aboveScopep, m_aboveCellp};
|
||||
m_packageScopes.emplace(nodep, m_scopep);
|
||||
|
||||
// Create scope for the current usage of this cell
|
||||
AstNode::user1ClearTree();
|
||||
nodep->addMembersp(m_scopep);
|
||||
|
||||
iterateChildren(nodep);
|
||||
}
|
||||
void visit(AstCellInline* nodep) override { //
|
||||
if (v3Global.opt.vpi()) {
|
||||
@@ -334,10 +332,8 @@ class ScopeCleanupVisitor final : public VNVisitor {
|
||||
void visit(AstScope* nodep) override {
|
||||
// Want to ignore blocks under it
|
||||
VL_RESTORER(m_scopep);
|
||||
{
|
||||
m_scopep = nodep;
|
||||
iterateChildren(nodep);
|
||||
}
|
||||
m_scopep = nodep;
|
||||
iterateChildren(nodep);
|
||||
}
|
||||
|
||||
virtual void movedDeleteOrIterate(AstNode* nodep) {
|
||||
|
||||
Reference in New Issue
Block a user