Internals: MAJOR CHANGE. Combine V3Link and V3LinkDot stages for structures.

Functionality should be similar, but may introduce instability in resolving variables/cells.
Final merge from dot.
This commit is contained in:
Wilson Snyder
2012-07-21 17:12:42 -04:00
parent a2f49063e2
commit 8b9b7178a2
15 changed files with 843 additions and 916 deletions
+1 -8
View File
@@ -142,24 +142,17 @@ private:
// Remap var names and replace lower Begins
nodep->stmtsp()->iterateAndNext(*this);
if (nodep->genforp()) nodep->v3fatalSrc("GENFORs should have been expanded earlier");
}
m_namedScope = oldScope;
m_unnamedScope = oldUnnamed;
// Don't change var names of generate FOR() variables, but do recurse into a child FOR
nodep->flatsp()->iterateAndNext(*this);
// Cleanup
AstNode* addsp = NULL;
if (AstNode* stmtsp = nodep->stmtsp()) {
stmtsp->unlinkFrBackWithNext();
addsp = addsp->addNextNull(stmtsp);
}
if (AstNode* stmtsp = nodep->flatsp()) {
stmtsp->unlinkFrBackWithNext();
addsp = addsp->addNextNull(stmtsp);
}
if (addsp) {
nodep->replaceWith(addsp);
} else {