Internal code coverage fixes

This commit is contained in:
Wilson Snyder
2020-05-29 19:35:54 -04:00
parent 4cfa3f879a
commit fbc814b54a
26 changed files with 403 additions and 52 deletions
+2 -1
View File
@@ -192,7 +192,8 @@ private:
virtual void visit(AstVarRef* nodep) VL_OVERRIDE {
if (!VarFlags(nodep->varp()).m_notOpt) {
if (!m_cfuncp) { // Not in function, can't optimize
clearOptimizable(nodep->varp(), "BVnofunc");
// Perhaps impossible, but better safe
clearOptimizable(nodep->varp(), "BVnofunc"); // LCOV_EXCL_LINE
} else {
// If we're scoping down to it, it isn't really in the same block
if (!nodep->hierThis()) clearOptimizable(nodep->varp(), "HierRef");