I’d like to create a const object inside my SystemVerilog class. Does SystemVerilog support const objects (and how?), or does it only support const primitive types.
I’d like to do something like:
const my_object MY_CONST;
const begin
MY_CONST = new();
MY_CONST.param1 = "value1";
MY_CONST.param2 = "value2";
end
You can create constant class instances.