diff --git a/docs/_static/css/vlt_sphinx.css b/docs/_static/css/vlt_sphinx.css index bb9bc7e1e..8bfb935c4 100644 --- a/docs/_static/css/vlt_sphinx.css +++ b/docs/_static/css/vlt_sphinx.css @@ -1,16 +1,25 @@ -/*Verilator blue #008fd7; set in html*/ +/* Verilator blue #008fd7; set in html */ + .wy-side-nav-search > div.version { - color: #111; + color: #111; } -.fa-github::before, .icon-github::before { - content: ""; + +.fa-github::before, +.icon-github::before { + content: ""; } -.fa-home::before, .icon-home::before { - content: ""; + +.fa-home::before, +.icon-home::before { + content: ""; } -.fa-arrow-circle-right::before, .icon-circle-arrow-right::before { - content: ""; + +.fa-arrow-circle-right::before, +.icon-circle-arrow-right::before { + content: ""; } -.fa-arrow-circle-left::before, .icon-circle-arrow-left::before { - content: ""; + +.fa-arrow-circle-left::before, +.icon-circle-arrow-left::before { + content: ""; } diff --git a/src/V3AstNodes.cpp b/src/V3AstNodes.cpp index d51f70fae..d878aa615 100644 --- a/src/V3AstNodes.cpp +++ b/src/V3AstNodes.cpp @@ -1458,10 +1458,10 @@ void AstRefDType::dump(std::ostream& str) const { if (!s_recursing) { // Prevent infinite dump if circular typedefs s_recursing = true; str << " -> "; - if (typedefp()) { - typedefp()->dump(str); - } else if (subDTypep()) { - subDTypep()->dump(str); + if (const auto subp = typedefp()) { + subp->dump(str); + } else if (const auto subp = subDTypep()) { + subp->dump(str); } s_recursing = false; } @@ -1506,7 +1506,8 @@ void AstNodeArrayDType::dump(std::ostream& str) const { } string AstPackArrayDType::prettyDTypeName() const { std::ostringstream os; - os << subDTypep()->prettyDTypeName() << declRange(); + if (const auto subp = subDTypep()) os << subp->prettyDTypeName(); + os << declRange(); return os.str(); } string AstUnpackArrayDType::prettyDTypeName() const { diff --git a/src/V3Graph.cpp b/src/V3Graph.cpp index f292f478f..71070cee2 100644 --- a/src/V3Graph.cpp +++ b/src/V3Graph.cpp @@ -133,10 +133,10 @@ void V3GraphVertex::v3errorEnd(std::ostringstream& str) const { nsstr << endl; nsstr << "-vertex: " << this << endl; } - if (!fileline()) { - V3Error::v3errorEnd(nsstr); + if (FileLine* const flp = fileline()) { + flp->v3errorEnd(nsstr); } else { - fileline()->v3errorEnd(nsstr); + V3Error::v3errorEnd(nsstr); } } void V3GraphVertex::v3errorEndFatal(std::ostringstream& str) const {