2017-11-23 19:55:32 +00:00
|
|
|
// DESCRIPTION: Verilator: Verilog Test module
|
|
|
|
//
|
2020-03-21 15:24:24 +00:00
|
|
|
// This file ONLY is placed under the Creative Commons Public Domain, for
|
|
|
|
// any use, without warranty, 2017 by Wilson Snyder.
|
|
|
|
// SPDX-License-Identifier: CC0-1.0
|
2017-11-23 19:55:32 +00:00
|
|
|
|
|
|
|
module t (/*AUTOARG*/);
|
|
|
|
|
|
|
|
logic [31:0] array_assign [3:0];
|
|
|
|
|
|
|
|
logic [31:0] larray_assign [0:3];
|
|
|
|
|
2020-08-22 06:23:26 +00:00
|
|
|
logic [31:0] array_assign2 [6:3];
|
|
|
|
|
|
|
|
logic [31:0] larray_assign2 [3:6];
|
2017-11-23 19:55:32 +00:00
|
|
|
initial begin
|
|
|
|
array_assign[1:3] = '{32'd4, 32'd3, 32'd2};
|
|
|
|
larray_assign[3:1] = '{32'd4, 32'd3, 32'd2};
|
2020-08-22 06:23:26 +00:00
|
|
|
array_assign2[4:6] = '{32'd4, 32'd3, 32'd2};
|
|
|
|
larray_assign2[6:4] = '{32'd4, 32'd3, 32'd2};
|
2017-11-23 19:55:32 +00:00
|
|
|
|
|
|
|
array_assign[4:3] = '{32'd4, 32'd3};
|
|
|
|
array_assign[1:-1] = '{32'd4, 32'd3};
|
2019-09-17 19:17:23 +00:00
|
|
|
array_assign[1:1] = '{32'd4}; // Ok
|
|
|
|
larray_assign[1:1] = '{32'd4}; // Ok
|
2020-08-22 06:23:26 +00:00
|
|
|
array_assign2[4:4] = '{32'd4}; // Ok
|
|
|
|
larray_assign2[4:4] = '{32'd4}; // Ok
|
2017-11-23 19:55:32 +00:00
|
|
|
|
|
|
|
$write("*-* All Finished *-*\n");
|
|
|
|
$finish;
|
|
|
|
end
|
|
|
|
endmodule
|