diff --git a/src/V3AstNodeOther.h b/src/V3AstNodeOther.h index 02db326c4..2695c9c49 100644 --- a/src/V3AstNodeOther.h +++ b/src/V3AstNodeOther.h @@ -1041,22 +1041,6 @@ public: void isStatic(bool flag) { m_isStatic = flag; } bool isStatic() const { return m_isStatic; } }; -class AstConstraintBefore final : public AstNode { - // Constraint solve before item - // @astgen op1 := lhssp : List[AstNodeExpr] - // @astgen op2 := rhssp : List[AstNodeExpr] -public: - AstConstraintBefore(FileLine* fl, AstNodeExpr* lhssp, AstNodeExpr* rhssp) - : ASTGEN_SUPER_ConstraintBefore(fl) { - addLhssp(lhssp); - addRhssp(rhssp); - } - ASTGEN_MEMBERS_AstConstraintBefore; - bool isGateOptimizable() const override { return false; } - bool isPredictOptimizable() const override { return false; } - bool sameNode(const AstNode* /*samep*/) const override { return true; } -}; - class AstCoverBin final : public AstNode { // Captures data for a coverpoint 'bins' declaration // @astgen op1 := rangesp : List[AstNode] diff --git a/src/V3AstNodeStmt.h b/src/V3AstNodeStmt.h index 50f7e738b..84003c2cb 100644 --- a/src/V3AstNodeStmt.h +++ b/src/V3AstNodeStmt.h @@ -461,6 +461,21 @@ public: bool sameNode(const AstNode* samep) const override { return true; } // Ignore name in comments virtual bool showAt() const { return m_showAt; } }; +class AstConstraintBefore final : public AstNodeStmt { + // Constraint solve before item + // @astgen op1 := lhssp : List[AstNodeExpr] + // @astgen op2 := rhssp : List[AstNodeExpr] +public: + AstConstraintBefore(FileLine* fl, AstNodeExpr* lhssp, AstNodeExpr* rhssp) + : ASTGEN_SUPER_ConstraintBefore(fl) { + addLhssp(lhssp); + addRhssp(rhssp); + } + ASTGEN_MEMBERS_AstConstraintBefore; + bool isGateOptimizable() const override { return false; } + bool isPredictOptimizable() const override { return false; } + bool sameNode(const AstNode* /*samep*/) const override { return true; } +}; class AstConstraintExpr final : public AstNodeStmt { // Constraint expression // @astgen op1 := exprp : AstNodeExpr