Skip to content

Commit 63c6f4b

Browse files
authored
Merge pull request #372 from diffblue/vector_types1
Verilog: add a test for the vector types
2 parents dcaa4c9 + 9f3f051 commit 63c6f4b

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
CORE
2+
vector_types1.sv
3+
--bound 0
4+
^EXIT=0$
5+
^SIGNAL=0$
6+
--
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
module main;
2+
3+
wire [7:0] implicit;
4+
wire bit [7:0] some_bits;
5+
wire logic [7:0] some_logic;
6+
wire unsigned [7:0] implicit_unsigned;
7+
wire bit unsigned [7:0] some_bits_unsigned;
8+
wire logic unsigned [7:0] some_logic_unsigned;
9+
wire signed [7:0] implicit_signed;
10+
wire bit signed [7:0] some_bits_signed;
11+
wire logic signed [7:0] some_logic_signed;
12+
13+
// expected to pass
14+
p0: assert property ($bits(implicit) == 8);
15+
p1: assert property ($bits(some_bits) == 8);
16+
p2: assert property ($bits(some_logic) == 8);
17+
p3: assert property ($bits(implicit_unsigned) == 8);
18+
p4: assert property ($bits(some_bits_unsigned) == 8);
19+
p5: assert property ($bits(some_logic_unsigned) == 8);
20+
p6: assert property ($bits(implicit_signed) == 8);
21+
p7: assert property ($bits(some_bits_signed) == 8);
22+
p8: assert property ($bits(some_logic_signed) == 8);
23+
24+
endmodule

0 commit comments

Comments
 (0)