Hi all, I have a data structure that I'm building, and I'm wondering if it's possible to parameterize the datatype to be unsigned or signed. Here's an example of what I'd imagine (although it's not valid syntax)
module myModule # (parameter UNSIGNED = 1) generate if (UNSIGNED == 1) input logic [7:0] my_bus; else input logic signed [7:0] my_bus; endgenerate) // data structure guts here endmodule
Is something like this possible? Thanks for taking a look!