typedef struct packed {
logic in_use;
logic fully_received;
} t_packet_info;
t_packet_info packets[A-1:0][B-1:0];
t_packet_info packet_ptr;
assign packet_ptr = packets[ a ][ b ];
always_ff @(posedge clk) begin
packet_ptr <= //any value
end
I want to use packet_ptr
to be able to allocate it in an always_ff
as if I wrote packets[ a ][ b ]
.
可能吗?我想避免使用宏。