diff --git a/net_expr.cc b/net_expr.cc index 4a0ee3008..5cd29e013 100644 --- a/net_expr.cc +++ b/net_expr.cc @@ -304,7 +304,7 @@ ivl_variable_type_t NetECReal::expr_type() const return IVL_VT_REAL; } -NetECRealParam::NetECRealParam(NetScope*s, perm_string n, const verireal&v) +NetECRealParam::NetECRealParam(const NetScope*s, perm_string n, const verireal&v) : NetECReal(v), scope_(s), name_(n) { } diff --git a/netlist.cc b/netlist.cc index a83b5f5e3..21a44faea 100644 --- a/netlist.cc +++ b/netlist.cc @@ -2391,7 +2391,7 @@ void NetEConst::trim() expr_width(value_.len()); } -NetEConstParam::NetEConstParam(NetScope*s, perm_string n, const verinum&v) +NetEConstParam::NetEConstParam(const NetScope*s, perm_string n, const verinum&v) : NetEConst(v), scope_(s), name_(n) { cast_signed_base_(v.has_sign()); diff --git a/netlist.h b/netlist.h index 68514c3e6..dd6b9dbb7 100644 --- a/netlist.h +++ b/netlist.h @@ -2175,7 +2175,7 @@ class NetEConstEnum : public NetEConst { class NetEConstParam : public NetEConst { public: - explicit NetEConstParam(NetScope*scope, perm_string name, + explicit NetEConstParam(const NetScope*scope, perm_string name, const verinum&val); ~NetEConstParam(); @@ -2188,7 +2188,7 @@ class NetEConstParam : public NetEConst { virtual NetEConstParam* dup_expr() const; private: - NetScope*scope_; + const NetScope*scope_; perm_string name_; }; @@ -2236,7 +2236,7 @@ class NetECString : public NetEConst { class NetECRealParam : public NetECReal { public: - explicit NetECRealParam(NetScope*scope, perm_string name, + explicit NetECRealParam(const NetScope*scope, perm_string name, const verireal&val); ~NetECRealParam(); @@ -2249,7 +2249,7 @@ class NetECRealParam : public NetECReal { virtual NetECRealParam* dup_expr() const; private: - NetScope*scope_; + const NetScope*scope_; perm_string name_; };