Put display scope tracking under special node type

git-svn-id: file://localhost/svn/verilator/trunk/verilator@936 77ca24e4-aefa-0310-84f0-b9a241c72d87
This commit is contained in:
Wilson Snyder
2007-06-14 16:41:32 +00:00
parent 5b620a8dc5
commit c18f9da400
10 changed files with 49 additions and 22 deletions
+2 -2
View File
@@ -233,10 +233,10 @@ private:
}
nodep->iterateChildren(*this);
}
virtual void visit(AstDisplay* nodep, AstNUser*) {
virtual void visit(AstScopeName* nodep, AstNUser*) {
// If there's a %m in the display text, we add a special node that will contain the name()
// Similar code in V3Begin
if (m_cellp && nodep->needScopeTracking()) {
if (m_cellp) {
// To keep correct visual order, must add before other Text's
AstNode* afterp = nodep->scopeAttrp();
if (afterp) afterp->unlinkFrBackWithNext();