Guest
I want to make a type based on a parameter (DO_THIS), like this:
if( DO_THIS ) begin
typedef struct packed {
logic val;
logic a;
logic b;
logic c;
logic d;
} my_t;
end else begin
typedef struct packed {
logic val;
logic a;
logic b;
} my_t;
end
Is there any way to do this other than a generate block? My lint tool does not like this with a generate block.
if( DO_THIS ) begin
typedef struct packed {
logic val;
logic a;
logic b;
logic c;
logic d;
} my_t;
end else begin
typedef struct packed {
logic val;
logic a;
logic b;
} my_t;
end
Is there any way to do this other than a generate block? My lint tool does not like this with a generate block.