mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 01:54:01 +02:00
Support [#] in dotted cell names
git-svn-id: file://localhost/svn/verilator/trunk/verilator@863 77ca24e4-aefa-0310-84f0-b9a241c72d87
This commit is contained in:
+9
-3
@@ -92,12 +92,19 @@ string AstNode::shortName() const {
|
||||
return pretty;
|
||||
}
|
||||
|
||||
string AstNode::prettyName(const string& namein) {
|
||||
string AstNode::dedotName(const string& namein) {
|
||||
string pretty = namein;
|
||||
string::size_type pos;
|
||||
while ((pos=pretty.find("__DOT__")) != string::npos) {
|
||||
pretty.replace(pos, 7, ".");
|
||||
}
|
||||
if (pretty.substr(0,4) == "TOP.") pretty.replace(0,4,"");
|
||||
return pretty;
|
||||
}
|
||||
|
||||
string AstNode::prettyName(const string& namein) {
|
||||
string pretty = namein;
|
||||
string::size_type pos;
|
||||
while ((pos=pretty.find("__BRA__")) != string::npos) {
|
||||
pretty.replace(pos, 7, "[");
|
||||
}
|
||||
@@ -107,8 +114,7 @@ string AstNode::prettyName(const string& namein) {
|
||||
while ((pos=pretty.find("__PVT__")) != string::npos) {
|
||||
pretty.replace(pos, 7, "");
|
||||
}
|
||||
if (pretty.substr(0,4) == "TOP.") pretty.replace(0,4,"");
|
||||
return pretty;
|
||||
return AstNode::dedotName(pretty);
|
||||
}
|
||||
|
||||
int AstNode::widthPow2() const {
|
||||
|
||||
Reference in New Issue
Block a user