diff --git a/src/V3Width.cpp b/src/V3Width.cpp index 84b4c8aea..4f009d90a 100644 --- a/src/V3Width.cpp +++ b/src/V3Width.cpp @@ -1727,14 +1727,13 @@ class WidthVisitor final : public VNVisitor { } void visit(AstCgOptionAssign* nodep) override { // Extract covergroup option values and store in AstClass before deleting - AstClass* const cgClassp = m_cgClassp; - if (cgClassp) { + if (m_cgClassp) { // Process supported options if (nodep->name() == "auto_bin_max" && !nodep->typeOption()) { // Extract constant value if (AstConst* constp = VN_CAST(nodep->valuep(), Const)) { - cgClassp->cgAutoBinMax(constp->toSInt()); - UINFO(6, " Covergroup " << cgClassp->name() << " option.auto_bin_max = " + m_cgClassp->cgAutoBinMax(constp->toSInt()); + UINFO(6, " Covergroup " << m_cgClassp->name() << " option.auto_bin_max = " << constp->toSInt() << endl); } }