We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5f8de8c commit 2f044c3Copy full SHA for 2f044c3
regression/verilog/case/case5.desc
@@ -0,0 +1,10 @@
1
+KNOWNBUG
2
+case5.sv
3
+--module main --bound 0
4
+^EXIT=0$
5
+^SIGNAL=0$
6
+--
7
+^warning: ignoring
8
9
+This gives the wrong result.
10
+
regression/verilog/case/case5.sv
@@ -0,0 +1,30 @@
+module main;
+ reg [31:0] resultA, resultB;
+ // All case expressions are extended to the longest case
+ // or case item expression.
+ initial begin
+ resultA = 10;
11
+ case(1'b1 << 8)
12
+ 0: resultA = 0; // 32 bits!
13
+ 1'b1: resultA = 1;
14
+ endcase
15
16
+ assert(resultA == 10);
17
+ end
18
19
20
+ resultB = 10;
21
22
23
+ 1'b0: resultB = 0; // just 1 bit!
24
+ 1'b1: resultB = 1;
25
26
27
+ assert(resultB == 0);
28
29
30
+endmodule
0 commit comments