Sign in
foss-fpga-tools
/
third_party
/
Surelog
/
4a79a47b7dd03dd4b2776ee40322b0149935d234
/
.
/
src
/
Testcases
/
Google
/
chapter-12
/
12.5--case.sv
blob: 45654fa5bc9599ddd9b7a472cc074168a7d2738b [
file
] [
log
] [
blame
]
/*
:name: case
:description: A module testing case statement
:should_fail: 0
:tags: 12.5
*/
module
case_tb
();
wire
[
3
:
0
]
a
=
0
;
reg
[
3
:
0
]
b
=
0
;
always
begin
case
(
a
)
4
'h0: b = 12;
4'
h3
:
b
=
4
;
4
'hf: b = 8;
default b = 0;
endcase
end
endmodule