mirror of
https://github.com/YosysHQ/yosys
synced 2025-11-14 18:11:18 +00:00
Add tests for implicit wires in generate blocks.
Signed-off-by: Yannick Lamarre <yan.lamarre@gmail.com>
This commit is contained in:
parent
109abd3224
commit
702e1f2467
2 changed files with 36 additions and 0 deletions
20
tests/verilog/genblk_wire.sv
Normal file
20
tests/verilog/genblk_wire.sv
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
module gold(a, b);
|
||||
output wire [1:0] a;
|
||||
input wire [1:0] b;
|
||||
genvar i;
|
||||
for (i = 0; i < 2; i++) begin
|
||||
wire x;
|
||||
assign x = b[i];
|
||||
assign a[i] = x;
|
||||
end
|
||||
endmodule
|
||||
|
||||
module gate(a, b);
|
||||
output wire [1:0] a;
|
||||
input wire [1:0] b;
|
||||
genvar i;
|
||||
for (i = 0; i < 2; i++) begin
|
||||
assign x = b[i];
|
||||
assign a[i] = x;
|
||||
end
|
||||
endmodule
|
||||
Loading…
Add table
Add a link
Reference in a new issue